Hi
I'm quite newbie with NSIS but here is my quetion:
Is it possible create outputfile to desktop?
OutFile "${DESKTOP}..." or Outfile "$DESKTOP..." won't work
because it just gives "Can't open output file" error.
Thanks.
Joni Halmelahti
OutFile to desktop
10 posts
$DESKTOP is a run-time variable. You have to give the full path.
It's 'C:\Documents and Settings\UserName\Desktop' for Windows 2000/XP.
It's 'C:\Documents and Settings\UserName\Desktop' for Windows 2000/XP.
Right.
But i'm intend use that script in different platforms like windows 95/98/NT4/2000 and XP so how should i configure that OutFile to work with those?
-jh
But i'm intend use that script in different platforms like windows 95/98/NT4/2000 and XP so how should i configure that OutFile to work with those?
-jh
Do you want to distribute the script or the installer that is compiled from it?
I think he wants to distribute the script. OutFile is the filename of the installer to generate.
Joost, would the same concept you had me apply to using /DMUI_VERSION apply to him somehow? Possibly defining the OutFile outside of the script?
I made a small application to compile Visual Basic projects and set MUI_VERSION and MUI_NAME automatically. Then it just runs the MakeNSIS.exe file on its own.
I made a small application to compile Visual Basic projects and set MUI_VERSION and MUI_NAME automatically. Then it just runs the MakeNSIS.exe file on its own.
Yep. A solution is to create an app that gets the desktop directory (using an API call), LAUNCH makensis with a /DDESKTOPDIR="dir" flag and use "${DESKTOPDIR}" for the directory.
Or just create another installer that will call makensis with /X"OutFile $DESKTOP\myInstall.exe". There is no need for another program.
Some example code? Pls. 🙂
In the compiler script:
In the main script (if second method [/D] used):Section compile
Exec '"${NSISDIR}\makensisw.exe" /X"OutFile $DESKTOP\myInstall.exe" "my script.nsi"'
# or
Exec '"${NSISDIR}\makensisw.exe" /D"DESKTOP=$DESKTOP" "my script.nsi"'
SectionEnd
OutFile "${DESKTOP}\myInstall.exe"