View Full Version : Deferred CA can't find dll

06-03-2004, 04:10 PM

I have a deferred CA calling a func of a dll stored in binary table.

But when installing, there's always an error popup saying can't find the dll in
%temp% directory.

This CA is right before Action InstallFinalize.

I have other immediate CAs which depends on the same DLL and runs w/o problem.

Anything wrong with my settings?


06-03-2004, 04:22 PM
Can you elaborate on the custom action settings as it appears in Custom Actions view?

06-03-2004, 04:37 PM
It's good to hear someone reply. thx

I've attached the jpg showing the settings

06-03-2004, 04:40 PM
I can't see the attachement of my posting. repost it now

06-03-2004, 05:04 PM
Is the error from Windows Installer Service saying it can't find MyCustomAction.dll to run the custom action? Or is the error from MyCustomACtion.dll while executing the custom action? It will be helpful to have the exact error message.

Since it's custom dll, it could be some issues as a result of running in deferred execute sequence. Only a limited set of properties is available during deferred execute sequence. That will be the first thing I would verify.

06-03-2004, 05:20 PM
The error message is sth like
"Cannot find %temp%\MyCustomAction.dll"

Where the %temp% is current user's temp directory like doc~\user\temp

This deferred CA doesn't query any properties. It only query the registry system using standard functions like "RegCreateKeyEx()" etc.

If I set this CA as immediate action, it can run. But the problem is that at that moment, installation of files hasn't been started yet. This CA need to change some files in the [INSTALLDIR].

I have 2 quesrions,

1. Is it I can have 3 choices to do this?
a. use current setting
b. use immediate CA and schedule it right after InstallationFinalise.
c. use committed CA and schedule it anywhere

2. Can a deferred/comitt CA use DLL stored in binary table?


(BTW, from your point of view, the current settings seems right, correct?)

06-03-2004, 05:49 PM
1. Actually, there are two options. Commit custom action is also executed in deferred execute sequence. Hence, it has the same restrictions of a deferred custom action.

2. I don't see why not.

How do you access INSTALLDIR property? It won't be available readily as a property during deferred execute sequence.

06-03-2004, 05:56 PM
INSTALLDIR has been set in a registry key. That's why in the CA, I query the registry to get it.

Anything wrong with my settings?

Is there any way (other than CA) that I can modify files during installation? This seems a pretty common tasks needed by most installations.