Winamp & Shoutcast Forums

Winamp & Shoutcast Forums (http://forums.winamp.com/index.php)
-   NSIS Discussion (http://forums.winamp.com/forumdisplay.php?f=65)
-   -   InstallDir problem (http://forums.winamp.com/showthread.php?t=258855)

xno 3rd November 2006 21:36

InstallDir problem
 
Hi all,

I have a little problem with the automatic completion of a directory with InstallDir:

I have two variables $CompanyName and $SoftwareName which are initialized into .OnInit function and I want to use them to append the installation directory.

Then, I have the two following lines:

InstallDir "$PROGRAMFILES\$CompanyName\$SoftwareName"

and, into .OnInit function:

StrCpy $INSTDIR "$PROGRAMFILES\$CompanyName\$SoftwareName"

The problem is the auto-completion of the directory choosen by the user with the directory page: Only the value of the variable $SoftwareName is append to the directory choosen. It is obviously normal because NSIS appends only the string following the last backslash. :cry:

Then, my question is: Is there a way to have my two variables appended to the directory choosen by the user?

Thanks.

:)

kichik 4th November 2006 02:33

You can use InstallDir $PROGRAMFILES\$CombinedVar and then copy something\something into $CombinedVar.

xno 4th November 2006 07:56

Yes!

Thank you very much!!! :)

This is so simply, I did not even think to try that trick.

:igor:


All times are GMT. The time now is 04:33.

Copyright © 1999 - 2010 Nullsoft. All Rights Reserved.