Archive: Install Directory problems


Install Directory problems
Hi,

What I am trying to do is no doubt simple in the scheme of NSIS however I cannot work out the syntax.

I am using InstallDirRegKey to find the directory I want to install the add-in. But I don't want it to go that directory I naturally want it to go to directory below this for our app.

Now I can force it (by changing the SetOutPath "$INSTDIR\" to add the additional directories) but I would like it displayed on the "Choose Install Location" page


; Define your application name
!define APPNAME "HL2 Co-op: Follow Freeman"
!define APPNAMEANDVERSION "HL2 Co-op: Follow Freeman Beta 2"

; Main Install settings
Name "${APPNAMEANDVERSION}"
InstallDir "$PROGRAMFILES\HL2 Co-op: Follow Freeman"
InstallDirRegKey HKEY_CURRENT_USER Software\Valve\Steam "SourceModInstallPath"
OutFile "hl2coop.exe"


How do I do that?

I did use the forum search but "InstallDirRegKey" had no results found. Stupid old vbulletin software.

Thanks in advance.

Simply modify $INSTDIR to your liking in .onInit.

!include LogicLib.nsh
Function .onInit
${If} $INSTDIR != ""
StrCpy $INSTDIR $INSTDIR\Blah
${EndIf}
FunctionEnd

Thanks mate