|
|
#1 |
|
Junior Member
Join Date: Sep 2007
Posts: 5
|
I haven't used nsis in about 2 years now I need to do the same thing I did before but I cann't remember how. :-(
This is what I have so far but it's not right. :-( I just need to run the exe file but select where it is installed. *********************** Name "Installer" OutFile "installer.exe" ; The default installation directory InstallDir $PROGRAMFILES\Example1 ;-------------------------------- ; Pages Page directory Page instfiles ;-------------------------------- ; The stuff to install Section "" ;No components page, name is not important ; Set output path to the installation directory. SetOutPath $INSTDIR SectionEnd ; end the section Section Exec '"$INSTDIR\jtpsetup.exe" SectionEnd ******************************************* Thanks for any help anyone can provide. |
|
|
|
|
|
#2 |
|
M.I.A.
[NSIS Dev, Mod] Join Date: Oct 2001
Location: Israel
Posts: 11,343
|
SetOutPath sets where the file is installed, but you don't install any file. You need to use File to install a file.
NSIS FAQ | NSIS Home Page | Donate $ "I hear and I forget. I see and I remember. I do and I understand." -- Confucius |
|
|
|
|
|
#3 |
|
Junior Member
Join Date: Sep 2007
Posts: 5
|
not exactly sure what that means...
|
|
|
|
|
|
#4 |
|
Major Dude
Join Date: May 2005
Location: New Zealand
Posts: 916
|
Yeah, where is 'jtpsetup.exe' in your installer? Should be something like:
; The stuff to install Section "" ;No components page, name is not important ; Set output path to the installation directory. SetOutPath $INSTDIR ;Extract the file File "jtpsetup.exe" SectionEnd ; end the section "Only a MouseHelmet will save you from a MouseTrap" -Jason Ross (Me) NSIS 3 POSIX Ninja Wiki Profile |
|
|
|
|
|
#5 |
|
Junior Member
Join Date: Sep 2007
Posts: 5
|
I got an error is this what you ment?
********************************************88 Name "Installer" OutFile "installer.exe" ; The default installation directory InstallDir $PROGRAMFILES\test ;-------------------------------- ; Pages Page directory Page instfiles ;-------------------------------- ; The stuff to install Section "" ;No components page, name is not important ; Set output path to the installation directory. SetOutPath $INSTDIR ; The stuff to install Section "" ;No components page, name is not important ; Set output path to the installation directory. SetOutPath $INSTDIR ;Extract the file File "jtpsetup.exe" SectionEnd ; end the section ******************************** |
|
|
|
|
|
#6 |
|
Junior Member
|
Name "Installer"
OutFile "installer.exe" ; The default installation directory InstallDir $PROGRAMFILES\test ;-------------------------------- ; Pages Page directory Page instfiles ;-------------------------------- ; The stuff to install Section "Install" ;Names are important for our sanity ; Set output path to the installation directory. SetOutPath $INSTDIR ;Extract the file File "jtpsetup.exe" SectionEnd ; end the 'Install' section ; The stuff to execute Section "Execute" ;Names are important for our sanity Exec '"$INSTDIR\jtpsetup.exe"' SectionEnd ; end the 'Execute' section |
|
|
|
|
|
#7 |
|
Junior Member
Join Date: Sep 2007
Posts: 5
|
!define: "MUI_INSERT_NSISCONF"=""
Changing directory to: "C:\Documents and Settings\Joel\Desktop\Cool Installer" Processing script file: "C:\Documents and Settings\Joel\Desktop\Cool Installer\install.nsi" Name: "Installer" OutFile: "installer.exe" InstallDir: "$PROGRAMFILES\test" Page: directory Page: instfiles Section: "Install" SetOutPath: "$INSTDIR" File: "jtpsetup.exe" -> no files found. Usage: File [/nonfatal] [/a] ([/r] [/x filespec [...]] filespec [...] | /oname=outfile one_file_only) Error in script "C:\Documents and Settings\Joel\Desktop\Cool Installer\install.nsi" on line 24 -- aborting creation process |
|
|
|
|
|
#8 |
|
Junior Member
|
The .exe has to be in the same directory as the .nsi file or you have to change the path to it in the File directive.
Jon |
|
|
|
|
|
#9 |
|
Junior Member
Join Date: Sep 2007
Posts: 5
|
Sorry I didn't have it in the right folder it works now but instead of running the exe its just copying to the fold the user chooses. I'm really trying to get it to run the exe after not just move it to the folder. Is there a way to do that? Thanks for the help so far.
|
|
|
|
|
|
#10 |
|
Major Dude
Join Date: May 2005
Location: New Zealand
Posts: 916
|
It should be executed under all circumstances because you don't have a components page.
"Only a MouseHelmet will save you from a MouseTrap" -Jason Ross (Me) NSIS 3 POSIX Ninja Wiki Profile |
|
|
|
![]() |
|
|||||||
| Thread Tools | Search this Thread |
| Display Modes | |
|
|