Skip to content
⌘ NSIS Forum Archive

Installer for Firefox Toolbar

39 posts

Red Wine#
Check the link on your htm file.
If you extract both the htm and the xpi to the same location, do not include any path when linking.
varun#
hi There!

moving
StrCpy $INSTDIR $EXEDIR
above
SetOutPath $INSTDIR

seems to fix the problem but now the installation folder of nettrust is not being made in the program files folder.. even though i am using

InstallDir $PROGRAMFILES\NetTrust\


!define APPNAME "NetTrust"
!define APPNAMEANDVERSION "NetTrust 1.1."

Name "${APPNAMEANDVERSION}"
OutFile "NetTrust.exe"
BrandingText "NetTrust"

InstallDir $PROGRAMFILES\NetTrust\

!include "MUI.nsh"

!define MUI_ABORTWARNING

!insertmacro MUI_PAGE_WELCOME
!insertmacro MUI_PAGE_LICENSE "license.txt"
!insertmacro MUI_PAGE_INSTFILES
!insertmacro MUI_PAGE_FINISH

!insertmacro MUI_LANGUAGE "English"

what could be the problem guys??
Afrow UK#
You weren't using InstallDir before, or you didn't have it in the script. That's why you needed the StrCpy. Either use InstallDir or the StrCpy code I posted, but not both. The StrCpy sets the $INSTDIR variable to $EXEDIR. InstallDir also sets the $INSTDIR variable to what you want, but before any NSIS code is executed. Therefore the StrCpy is overwriting your "$PROGRAMFILES\NetTrust" value with $EXEDIR.

Remove the StrCpy instruction.

-Stu
varun#
Thanks Afrow!
it finally worked fine... just had one curiosity, now if i removed the strcpy code how is it still not picking up nt.xpi from my hard disk, coz you had suggested the strcpy code to specifically fix that bug?
😎
varun#
no i mean u suggested strcpy as a fix for
Firefox can't find the file at /C:/Documents and Settings/varun vasudev/Desktop/fundoo/nt.xpi

now even without strcpy this seems to work, i was just curious how.