cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
tcom36
Level 7

Format of paths in ini files

I have to define in an ini file the path to some configuration files. I managed to do that within an installScript MSI. InstallShield creates entries such as:

[editor]
configurationFile=C:\Program Files\myProgram\...

(C:\Program Files\myProgram being my [INSTALLDIR]

Unfortunately, the application can't handle this format as it interprets the '\' characters. The application reading this entry would need either a double backslash '\\' or forward slashes '/'.

Is there a way to generate the paths with \\ or / instead of \, or how could I solve the problem?
Labels (1)
0 Kudos
(2) Replies
RobertDickau
Flexera Alumni

Instead of using [INSTALLDIR] directly, perhaps create a custom action (InstallScript action using MsiGetProperty, StrReplace, and MsiSetProperty, for example) that makes your own property [INSTALLDIR_DOCTORED_UP] with the desired slash format, and then use that property in the INI view?
0 Kudos
tcom36
Level 7

Thank you Robert

I will try that, calling a custom action somewhere after selecting the target install dir to create a new installer property which I hopefully would be able to use in the ini-files.
0 Kudos