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: [BasicMSI] Get installation source path in InstallScript
Subscribe
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Subscribe
- Mute
- Printer Friendly Page
‎Jul 06, 2011
04:42 AM
[BasicMSI] Get installation source path in InstallScript
Hello,
I've only done BasicMSI setups in the past but now I'm trying to write a few lines of InstallScript to run it as a CustomAction during installation.
This script has to copy additional files from our installation DVD which are added *after* building the installer. They are allways placed in a fixed folder next to setup.exe/product.msi
I've tried several path constants like "SRCDIR" and "SourceDir", but they only resolve to a path within the %TEMP% folder of the computer and not to the actual DVD drive where the installation was launched from.
Using a simple EXE call before as the custom action and passed [SOURCEDIR] as a parameter and this worked fine so far. But why do I get different paths within the InstallScript?
- InstallShield 2010 Premier
- BasicMSI project
I've only done BasicMSI setups in the past but now I'm trying to write a few lines of InstallScript to run it as a CustomAction during installation.
This script has to copy additional files from our installation DVD which are added *after* building the installer. They are allways placed in a fixed folder next to setup.exe/product.msi
I've tried several path constants like "SRCDIR" and "SourceDir", but they only resolve to a path within the %TEMP% folder of the computer and not to the actual DVD drive where the installation was launched from.
Using a simple EXE call before as the custom action and passed [SOURCEDIR] as a parameter and this worked fine so far. But why do I get different paths within the InstallScript?
- InstallShield 2010 Premier
- BasicMSI project
(3) Replies
‎Jul 06, 2011
07:27 AM
SourceDir will refer to %Temp% folder incase you have a setup.exe that extracts the installation files to %Temp% before performing the actual install.
Installshield's setup.exe does that if you create a compressed setup.
This is correct in one sense. The msi files are extracted to the %Temp% folder, so the SourceDir property in the eyes of msi is %Temp%.
If you can get rid of the setup.exe, you can use the SourceDir property without any trouble. If you cannot another option would be to stream all the files that you need as SUPPORT files and then use SUPPORTDIR property.
This increases the install time as now there are more files to extract. This increase in time would be excruciating if the Support files you included are huge.
BEST OPTION THOUGH would be to use SETUPEXEDIR. But it has some things to take care of. Read this:
http://kb.flexerasoftware.com/doc/Helpnet/installshield12helplib/SETUPEXEDIR.htm
Installshield's setup.exe does that if you create a compressed setup.
This is correct in one sense. The msi files are extracted to the %Temp% folder, so the SourceDir property in the eyes of msi is %Temp%.
If you can get rid of the setup.exe, you can use the SourceDir property without any trouble. If you cannot another option would be to stream all the files that you need as SUPPORT files and then use SUPPORTDIR property.
This increases the install time as now there are more files to extract. This increase in time would be excruciating if the Support files you included are huge.
BEST OPTION THOUGH would be to use SETUPEXEDIR. But it has some things to take care of. Read this:
http://kb.flexerasoftware.com/doc/Helpnet/installshield12helplib/SETUPEXEDIR.htm