This website uses cookies. By clicking Accept, you consent to the use of cookies. Click Here to learn more about how we use cookies.
Turn on suggestions
Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.
- Revenera Community
- :
- InstallShield
- :
- InstallShield Forum
- :
- Re: How to get handle for current installation?
Subscribe
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Subscribe
- Mute
- Printer Friendly Page
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Jun 01, 2008
03:27 AM
How to get handle for current installation?
Hi,
I have a logging function which expect handle to the current installation
How do i get this handle?
Am i allow to create a simple custom action to save it in a global variable?
Thanks in advance
I have a logging function which expect handle to the current installation
How do i get this handle?
Am i allow to create a simple custom action to save it in a global variable?
Thanks in advance
(3) Replies
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Jun 02, 2008
09:59 AM
For InstallScript and C/C++ MSI DLL custom actions, the install handle is passed as the only parameter to your custom action function.
For VBScript type actions, the handle is implicitly used when you use the Session object (http://msdn.microsoft.com/en-us/library/aa371675(VS.85).aspx).
The install handle is not provided for EXE type custom actions.
For VBScript type actions, the handle is implicitly used when you use the Session object (http://msdn.microsoft.com/en-us/library/aa371675(VS.85).aspx).
The install handle is not provided for EXE type custom actions.
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Jun 03, 2008
03:41 AM
to save the handle in a global variable?
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Jun 05, 2008
10:30 AM
There should be no need to save the MSI handle in a global variable. You can save it in a global variable in the context of an InstallScript custom action (as in a single, discrete action). However, that global variable will be lost when the custom action ends and the next InstallScript custom action starts running, so you would need to save the handle again for each InstallScript custom action that runs.