Prev Previous Post   Next Post Next
Old 18th May 2006, 02:58   #1
karabey
Junior Member
 
Join Date: May 2006
Posts: 13
Create Shortcut and RUN exe after UNZIP

Hi,

How can i make for this Script a Shortcut for Desktop and start from the extracted Folder the EXE File and the end of the installer?


code:
;--------------------------------
;Include Modern UI

!include "MUI.nsh"


;--------------------------------
;General

; The name of the installer
Name "InetLoad Test"
OutFile "InetLoad.exe"
InstallDir $PROGRAMFILES\InetLoad

;--------------------------------
;Interface Settings

!define MUI_ABORTWARNING

;--------------------------------
;Pages & Languages

!insertmacro MUI_PAGE_WELCOME
!insertmacro MUI_PAGE_INSTFILES
!insertmacro MUI_PAGE_FINISH
!insertmacro MUI_LANGUAGE "English"
!define MUI_FINISHPAGE_RUN "$INSTDIR\MyFile.exe"

;SilentInstall silent
;--------------------------------
;Installer Sections
Section "Dummy Section" SecDummy

InitPluginsDir
NSISdl::download http://www.mydomain.com/myfile.zip "$PLUGINSDIR\myfile.zip"
Pop $R0 ;Get the return value
StrCmp $R0 "success" +3
MessageBox MB_OK "Download failed: $R0"
Quit

nsisunz::UnzipToLog "$PLUGINSDIR\myfile.zip" "$INSTDIR"
Pop $R0
StrCmp $R0 "success" +2
DetailPrint "$R0" ;print error message to log

CreateShortCut "$DESKTOP\MyFile.lnk" "$PLUGINSDIR\MyFile.exe"

SectionEnd



The Failure is here but how can i resolve it?

code:
!define MUI_FINISHPAGE_RUN "$INSTDIR\MyFile.exe"
CreateShortCut "$DESKTOP\MyFile.lnk" "$PLUGINSDIR\MyFile.exe"




Thx for every help...
karabey is offline   Reply With Quote
 
Go Back   Winamp & Shoutcast Forums > Developer Center > NSIS Discussion

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump