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

changing value of string table identifier within the Installscript

Is it possible to change the value of a string table identifier within the Installscript? I have an Installscript MSI project that creates two websites in IIS as well as virtual directories and application pools, and I would like for the user to be able to provide names for these during the installation. I thought I could set these up in the IDE using a variable name for the ID_STRING value and then substitute the user response for each through the script. So far no luck, and I don't want to spend any more time on it if it isn't possible.

I would greatly appreciate any insight.
Labels (1)
0 Kudos
(5) Replies
wolverine
Level 4

Try and use following for accessing property in install script.

MsiSetProperty(ISMSI_HANDLE, "MYPROPERTY", svName);

Sandip Deshmukh
________________
Software Developer
0 Kudos

It only work with properties, not String Identifiers

0 Kudos
DebbieL
Level 17

0 Kudos
Mescalero
Level 7

Thanks, that is quite helpful. An additional question: is it possible to validate a user's port number response? i.e., ensure that the port number is not already assigned to another website in IIS?
0 Kudos
elganzo
Level 3

You are able to read with the method LoadStringFromStringTable ("ID_STRING", svIdString);
equivalent to svIdString = @ID_STRING; //Not ANSI supported
unlike of
MsiGetProperty (hMSI, "YourProperty", svYourProperty, nvSize); that it is for read Property values.
But there is no way to set values into StringTable, I think it is due to the string names are converted to its value in compilation time (I am not sure at 100% of this)
0 Kudos