Hi,
How can I set the value of a registry key och the name of a folder to the value of a global variable? If I can not, how would I go about to use a value retrieved during installation with a resouce?
This is a ready-only archive of the InstallSite Forum. You cannot post any new content here. / Dies ist ein Archiv des InstallSite Forums. Hier können keine neuen Beiträge veröffentlicht werden.
Global variables
Started by
jive02
, Mar 13 2002 11:40
5 replies to this topic
Posted 13 March 2002 - 13:36
Hi Jonas,
Sorry, but I'm not entirely sure what your question is. If it is how to read an Environment variable, then it depends on your target machine.
Also, I'm not what you mean with 'resource' . Could you please clarify
Ide
Sorry, but I'm not entirely sure what your question is. If it is how to read an Environment variable, then it depends on your target machine.
Also, I'm not what you mean with 'resource' . Could you please clarify
Ide
Posted 13 March 2002 - 18:46
hi,
With global variable I simply meen I variable defined at the top of my setup.rul. With resource I mean the resource pane.
So inte the resource pane I want to doubleclick a registry value and set it's value data to the variable I defined at the top of the setup.rul.
With global variable I simply meen I variable defined at the top of my setup.rul. With resource I mean the resource pane.
So inte the resource pane I want to doubleclick a registry value and set it's value data to the variable I defined at the top of the setup.rul.
- jonas
Posted 13 March 2002 - 21:59
Okay, I following what you're saying and, unfortunately this cannot be done. The resources are static items and cannot be linked to your global variables.
To get the affect you'll want, you'll either need to do it all in your script code -or- setup the base registry keys in the resources and define the associated registry values using your script.
To get the affect you'll want, you'll either need to do it all in your script code -or- setup the base registry keys in the resources and define the associated registry values using your script.
Posted 14 March 2002 - 14:13
Sorry to correct you TacoBell00, but there is a way this can be done, namely with the undocumented IS function TextSub.
For example, if you want to create the key 'AppPath', and assign it a value which is determined on runtime, follow this procedure:
- In the resources pane, assign the value <AppPath> (including the < >)
- In your code, before the calls to ComponentTransferData or ComponentMoveData. (i.e. before the OnMoving) set the value with TextSub("AppPath") = "C:\\TestPath" . After installation, your registrykey will contain the value "C:\TestPath".
For more information, see the IS KnowledgeBase article Q105042 - HOWTO: Creating a Variable in the Script That Can Be Referenced in the IDE.
Enjoy, Ide
For example, if you want to create the key 'AppPath', and assign it a value which is determined on runtime, follow this procedure:
- In the resources pane, assign the value <AppPath> (including the < >)
- In your code, before the calls to ComponentTransferData or ComponentMoveData. (i.e. before the OnMoving) set the value with TextSub("AppPath") = "C:\\TestPath" . After installation, your registrykey will contain the value "C:\TestPath".
For more information, see the IS KnowledgeBase article Q105042 - HOWTO: Creating a Variable in the Script That Can Be Referenced in the IDE.
Enjoy, Ide
Posted 14 March 2002 - 22:00
No problem Ide. I certainly wasn't aware of that undocumented feature.
I wonder if that can also be used for naming the program folder to which shortcuts are applied? Guess, I'll have to try it and find out.
I wonder if that can also be used for naming the program folder to which shortcuts are applied? Guess, I'll have to try it and find out.