JoderCoder
Level 8

Standard DLL Custom action at the end of install

I am trying to launch a standard DLL custom action upon user hitting Finish button at end of a successful install. However, I am getting this error: "Unknown source 'c$'".

Is there any problems with calling a custom action dll at the end of install? I tried calling an exe instead of a dll and it seemed to run fine.

Does anyone have any pointers what could be the reason here?

Thanks.
Labels (1)
0 Kudos
3 Replies
joshstechnij
Level 10 Flexeran
Level 10 Flexeran

Standard DLL actions rely on a file extracted at the beginning of the install UI or execute sequence (the file basically describes each standard DLL action, such as where the source DLL is located, the entry point and prototype of the function to call, etc.). This file is cleaned up (deleted) after the execute sequence has completed. Since the Finish button runs actions after the execute sequence, the file needed to run standard DLL actions successfully is no longer available.

By changing the parameters to your DLL function, you can use an MSI DLL type custom action from this point in the installation. MSI DLL actions take one parameter (MSIHANDLE) as input and return a UINT. The handle provides access to the installation session.
0 Kudos
JoderCoder
Level 8

Thanks very much! I'll try using MSI DLL now.. Basically I am trying to launch the application that I am installing - I cant use the launch exe custom action that IS provide as per the thread here: http://community.flexerasoftware.com/showthread.php?p=449540#post449540. What would be the best way to retrieve the file path? Using CustomActionData?

Thanks.
0 Kudos
joshstechnij
Level 10 Flexeran
Level 10 Flexeran

If the file is the keyfile of a component, the MsiGetComponentPath API can be used to obtain the full path to the file including the filename.

You can also use MsiGetProperty (for example, if the file installs to INSTALLDIR) to get the value of the path the file installs to, then append the file name to this path.
0 Kudos