cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Naveed
Level 6

At what action, SUPPORTDIR is availabe?

During the installation sequence, at what action/step the support files directory "SUPPORTDIR" becomes available to use?

i.e. When it gets created and files placed in it are available to be used by custom actions?

Thanks,
Naveed
Labels (1)
0 Kudos
(6) Replies
RobertDickau
Flexera Alumni

At ISSetupFilesExtract, I believe.
0 Kudos
kaneohe
Level 6

At what point do these files become unavilable? I need to run a bunch of actions after the InstallFiles has completed, to do system configuration, etc. I was using OnFirstUIAfter() but I now need the files in SUPPORTDIR don't seem to be available at that point. When I use a custom action placed immediately after InstallFiles it seems that my global variables and MSI properties are empty or not available to the custom action.

I need to call UseDLL() for a file in SUPPORTDIR and also retain access to my global InstallScript variables. How can I make this happen?
0 Kudos
RobertDickau
Flexera Alumni

The support files vanish with ISSetupFilesCleanup, I believe, and to get property values during deferred mode you'll want to use CustomActionData (the docs and these forums have information and examples).
0 Kudos
kaneohe
Level 6

So if there's a ISSetupFilesCleanup in both the UI and Execute sequences do the files disappear during the UI sequence? I've got 5 or 6 support files and by the time I get to my custom actions sequenced immediately after InstallFiles they're all missing. How do I retain these files into the Execute sequence?
0 Kudos
RobertDickau
Flexera Alumni

You can create a log file to see when standard and custom actions are being performed. I think the cleanup action is marked "execute only once", so the support files should not be cleaned up before InstallFiles.

P.S. As an example, I added file ReadMe.txt to the Language Independent section; then created a custom action that runs notepad.exe [SUPPORTDIR]\ReadMe.txt, set the action for deferred mode and placed after InstallFiles, and it launched as expected...
0 Kudos
kaneohe
Level 6

After much trial and error I have finally figured out the root cause of my problem. I was using the SUPPORTDIR pre-defined constant supplied by InstallScript. This apparently changes between the UI and Execute sequences. I've changed our code to pass SUPPORTDIR through CustomActionData. Using the value passed through CAD it looks to be working now.
0 Kudos