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
- :
- Basic MSI: How to get the Install Setup path in the script
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
‎Apr 30, 2008
09:49 AM
Basic MSI: How to get the Install Setup path in the script
Hi,
I am just trying to get the installation folder path, where the setup.exe is run from, during installation. Tried SETUPEXEDIR & SRCDIR. But so far, unsuccessful.
SRCDIR gives the temp path where the MSI file is extracted.
The script using SETUPEXEDIR below gives an empty path.
Could anyone please help...
Thanks,
Raj.
Please find script below:
==================
#include "ifx.h"
STRING SETUPEXEDIR[MAX_PATH + 1];
function MyFunction(hMSI)
NUMBER nBuffer;
begin
nBuffer = MAX_PATH + 1;
MsiGetProperty(ISMSI_HANDLE, "SETUPEXEDIR", SETUPEXEDIR, nBuffer);
// for testing: display the variable's value
MessageBox("SETUPEXEDIR = " + SETUPEXEDIR, INFORMATION);
end;
I am just trying to get the installation folder path, where the setup.exe is run from, during installation. Tried SETUPEXEDIR & SRCDIR. But so far, unsuccessful.
SRCDIR gives the temp path where the MSI file is extracted.
The script using SETUPEXEDIR below gives an empty path.
Could anyone please help...
Thanks,
Raj.
Please find script below:
==================
#include "ifx.h"
STRING SETUPEXEDIR[MAX_PATH + 1];
function MyFunction(hMSI)
NUMBER nBuffer;
begin
nBuffer = MAX_PATH + 1;
MsiGetProperty(ISMSI_HANDLE, "SETUPEXEDIR", SETUPEXEDIR, nBuffer);
// for testing: display the variable's value
MessageBox("SETUPEXEDIR = " + SETUPEXEDIR, INFORMATION);
end;
(3) Replies
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Apr 30, 2008
10:07 AM
I think you should use: SourceDir
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Apr 30, 2008
02:43 PM
SourceDir is the same as SRCDIR. It stores the SourceDir value.
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Apr 30, 2008
05:09 PM
Resolved. The value of SETUPEXEDIR is present only during the early stages of the installation. Towards the end the the value is empty.
![](/skins/images/A5EADE085F77DE82FB3B14D6B307AE6A/responsive_peak/images/icon_anonymous_message.png)