cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
tigerwood2006
Level 2

how to get [INSTALLDIR] from external EXE file?

Hi,

I am trying to modify a INI file on the target system, I am going to do this by invoking a external EXE file using a Custom Action after all other installation finish.
But one thing It requires is the directory where the installation goes, i.e. [INSTALLDIR]. How can I know that? Is there a way this piece of information can be saved (say to a text file) or access?

This whole process bugs me for quite some time, your help us much appreciated.

Thanks,
Labels (1)
0 Kudos
(3) Replies
fengzhou
Level 3

please try SRCDIR for uncompressed package, or PACKAGE_LOCATION for compressed package
0 Kudos
RobertDickau
Flexera Alumni

As an aside, can you use the INI File Changes view to write [INSTALLDIR] to your INI file?
0 Kudos
tigerwood2006
Level 2

I got the problem solved this afternoon.:) Actually by using the simple idea of searching, i managed to find out where the installed files go ([INSTALLDIR]). After i had this path information, I performed another search to find out where the target ini file is, and then modified the ini file with the [INSTALLDIR]. Sounds a bit complicated, but the logic is quite straight forward, much easier than to figure out how to achieve it using Installshield for a newbie like me.

But i am still interested to know how to use INI file changes to do it. I tried to use it but realize it might not possible, as the target location of the ini file is not static, for XP pro it is under ...\program files\application name\..; for XP 64bit, it is under ...\program files (x86)\application name\..; for Vista, it is under ...\user\...\local\Visual Store\appData\application name\.. I think INI file changes might not handle this?

Also i don't know how to use SRCDIR, is it the same thing as INSTALLDIR? when and how do we use these information, in VBScript?

Thansk for the answers
0 Kudos