Hello!
I have to create several setups with almost identical functionality, but different titles. Therefore, I have added a compiler variable PROGRAM_NAME, so I can set the "Product Name" value on the "Project Properties" page to "#PROGRAM_NAME#", and the output filename to "#PROGRAM_NAME#-setup".
This works very well, but I would now like to a language selection dialog. Unfortunately, this dialog is never displayed. When I change the "Product Name" property to a "regular" value without references to a compiler variable, the dialog is properly displayed.
Is anybody able to reproduce this problem? My guess is that InstallAware is unable to access the #PROGRAM_NAME#.mtx file.
Compiler variable in title suppresses language selector
-
- Posts: 55
- Joined: Tue Jan 09, 2007 12:20 pm
-
- Posts: 55
- Joined: Tue Jan 09, 2007 12:20 pm
Okay, I think I have found a workaround for this problem. I simply use some "neutral" name for my project, such as "SetupProject", and I set the TITLE variable according to my PROGRAM_NAME compiler variable at the very beginning of the script:
The "Support Files" folder now contains a file "SetupProject.mtx"; its name is not dependent on the PROGRAM_NAME compiler variable, so it can be used during run-time by all builds.
However, I have already encountered another problem. It seems that dereferenced compiler variables (such as "#PROGRAM_NAME#") are not resolved in localized strings. Is this correct?
Code: Select all
[compiler if Variable PROGRAM_NAME Equals Program1]
Set Variable TITLE to Program1
[compiler else]
Set Variable TITLE to Program2
[compiler end]
The "Support Files" folder now contains a file "SetupProject.mtx"; its name is not dependent on the PROGRAM_NAME compiler variable, so it can be used during run-time by all builds.
However, I have already encountered another problem. It seems that dereferenced compiler variables (such as "#PROGRAM_NAME#") are not resolved in localized strings. Is this correct?
-
- Posts: 3452
- Joined: Thu Dec 22, 2005 7:17 pm
- Contact:
Yes, this is correct. Because compiler variables are substituted at build time, they are not at all in the picture at runtime. So if you have such variables in localized text, they won't work. If you want to use localized variables in localized text, try the Localization Variable command.
Michael Nesmith
InstallAware
Home of The Next Generation MSI Installer
Get your free copy today - http://www.installaware.com/
InstallAware
Home of The Next Generation MSI Installer
Get your free copy today - http://www.installaware.com/
-
- Posts: 55
- Joined: Tue Jan 09, 2007 12:20 pm
Who is online
Users browsing this forum: No registered users and 118 guests