cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
DLee65
Level 13

Text file changes for registry files that include path statements

I have included in my installation a .REG file that needs to be modified by the installer.
I have setup the text file replacement set and all works except for one thing, cases where the file includes a path statement.

For instance one name is 'InstallPath'='{InstallPath}'. This is the value I place as the 'Find What' value.
For the Replace with value I have "InstallPath"="[INSTALLDIR]"

After the app is installed the value reads: "InstallPath"="C:\Program Files\Amazing Charts\"
The problem here is that the .reg file expects double slashes. The path above should read "C:\\Program Files\\AmazingCharts\\"
I thought about inserting a step to replace single slashes with double slashes but that would break the hive path which uses single slashes.

Is there a way to handle this situation so that my .reg file is updated correctly?
Does the text file Find What filter utilize regular expressions at all?

Do I need to pass this process off to an InstallScript or C# custom action to update the file properly?

Thank you.
Labels (1)
0 Kudos
(20) Replies