kobus
18th February 2004 11:08 UTC
Passing NSIS constat at runtime ...
I've got an installer that read default directories from
ini file during instalation and then give a chance to the
user to change it.
I want to set default dir to c:\windows\system directory
[NSIS constant $SYSDIR].
...
[section_xxx]
default_dir="$SYSDIR"
...
When I read it from INI file I've got variable $Dir with value "$SYSDIR". Is it possible to make installer to substitute $SYSDIR by real path to system directory. (something similar to indirect addressing) ?
Joost Verburg
18th February 2004 13:56 UTC
Use a value like %SystemRoot% and then change it to $SYSDIR.
StrCmp $Dir "%SystemRoot%" 0 +2
StrCpy $DIR $SYSDIR
kobus
18th February 2004 14:04 UTC
That's the way I finally did it.
I wonder if there is something like "indirect addressing" possible in NSIS scripting languge ...
If not, maybe it is worth of thinking about such a feature
in NSIS 3.0 :)
Thanks Joost and keep doing good work :up:
Kobus
Joost Verburg
18th February 2004 14:07 UTC
Features requests can be submitted at the project page.