Archive: [PLZ HELP] Vista Installer Problem


[PLZ HELP] Vista Installer Problem
Hey guys,

i really got a problem and not much time, so i would really appreciate it if we would find a solution for my problem which isnt as complicatet as other things i found in the forum, i think :)

The Problem is that our NSIS made Installer, wich is about 450Mb and contains many swf videos, need much time (about 2-4 minutes) till you see the first dialogbox of the installation.

After inserting the CD with the installer under Vista you first have to wait about 4 minutes. Then the liddle "Please wait while Setup is loading" -Window prompts up, BUT with directly 96% loaded, following from the first Install-dialog.

So dont misunderstand me, the installation routine works fine and our flash-application is installed correctly. But the initialisation of the installer really hangs up. Is there a way to show this "please wait while setup is loading" -window directly or what is the problem with the script. 'The RequestExecutionLevel admin' and 'SetShellVarContext all' i already inserted to my script.

I post the Script, perhaps it helps:

; Script generated by the HM NIS Edit Script Wizard.

; HM NIS Edit Wizard helper defines
!define PRODUCT_KEYNAME "Ratgeber compact"
!define PRODUCT_APPNAME "Computer Schritt fuer Schritt"
!define PRODUCT_NAME "Ratgeber compact Computer - Schritt für Schritt"
!define PRODUCT_PUBLISHER "TH"
!define PRODUCT_DIR_REGKEY "Software\Microsoft\Windows\CurrentVersion\App Paths\fspprojectorreglocation1234567890.exe"
!define PRODUCT_UNINST_KEY "Software\Microsoft\Windows\CurrentVersion\Uninstall\${PRODUCT_NAME}"
!define PRODUCT_UNINST_ROOT_KEY "HKLM"
;Bild im Start-Endsreen
!define MUI_WELCOMEFINISHPAGE_BITMAP "D:\Arbeit\QVC\Laptop Anwendung\Flash Anwendung\Installerbild\installerbild.bmp"
;Startseite Headertext und Leittext
!define MUI_WELCOMEPAGE_TITLE "Ratgeber compact Computer - Schritt für Schritt Installation"
!define MUI_WELCOMEPAGE_TITLE_3LINES
;Endseite Headertext und Leittext
!define MUI_FINISHPAGE_RUN_TEXT "Adobe Acrobat Reader installieren"
!define MUI_FINISHPAGE_RUN "$INSTDIR\acrobat reader\ar_setup.exe"
!define MUI_FINISHPAGE_TITLE "Installation abgeschlossen!"
!define MUI_FINISHPAGE_TEXT "Die Ratgeber compact Installation ist nun abgeschlossen. Um das beigefügte Handbuch zu lesen, benötigen Sie aber noch den Adobe Acrobat Reader (Version 7 oder höher). Klicken Sie auf 'Fertigstellen', um die Installation für den Adobe Acrobat Reader zu starten."

!include "C:\Programme\NSIS\Examples\System\System.nsh"
!include "C:\Programme\NSIS\Include\MUI.nsh"



; Welcome page
!insertmacro MUI_PAGE_WELCOME
; Directory page
!insertmacro MUI_PAGE_DIRECTORY
; Instfiles page
!insertmacro MUI_PAGE_INSTFILES

!insertmacro MUI_PAGE_FINISH

; Uninstaller pages
!insertmacro MUI_UNPAGE_INSTFILES

; Language files
!insertmacro MUI_LANGUAGE "German"

; MUI end ------
Name "${PRODUCT_NAME}"
OutFile "ratgeber_setup.exe"

InstallDir "$PROGRAMFILES\${PRODUCT_KEYNAME}\${PRODUCT_APPNAME}"
InstallDirRegKey HKLM "${PRODUCT_DIR_REGKEY}" ""
ShowInstDetails show
ShowUnInstDetails show
RequestExecutionLevel admin

Section -SETTINGS
SetOutPath "$INSTDIR"
SetOverwrite ifnewer
SectionEnd

Section "Ratgeber compact Computer - Schritt für Schritt" SEC01
SetOutPath "$INSTDIR"
SetOverwrite ifnewer
SetShellVarContext all
File /r "D:\Arbeit\QVC\Laptop Anwendung\Flash Anwendung\Final\"
CreateDirectory "$SMPROGRAMS\${PRODUCT_KEYNAME}\${PRODUCT_APPNAME}"
CreateShortCut "$SMPROGRAMS\${PRODUCT_KEYNAME}\${PRODUCT_APPNAME}\Ratgeber compact Computer starten.lnk" "$INSTDIR\Ratgeber compact starten.exe"
CreateShortCut "$DESKTOP\Ratgeber compact Computer starten.lnk" "$INSTDIR\Ratgeber compact starten.exe"
SectionEnd

;Section "Adobe Acrobat Reader"
; SetOutPath "$PROGRAMFILES\Acrobat Reader\"
; File "acrobat reader\ar_setup.exe"
;ExecWait "acrobat reader\ar_setup.exe"
;SectionEnd

Section -AdditionalIcons
SetShellVarContext all
CreateShortCut "$SMPROGRAMS\${PRODUCT_KEYNAME}\${PRODUCT_APPNAME}\Ratgeber compact Computer deinstallieren.lnk" "$INSTDIR\Ratgeber compact deinstallieren.exe"
SectionEnd

Section -Post
WriteUninstaller "$INSTDIR\Ratgeber compact deinstallieren.exe"
WriteRegStr HKLM "${PRODUCT_DIR_REGKEY}" "" "$INSTDIR\Ratgeber compact starten.exe"
WriteRegStr ${PRODUCT_UNINST_ROOT_KEY} "${PRODUCT_UNINST_KEY}" "DisplayName" "$(^Name)"
WriteRegStr ${PRODUCT_UNINST_ROOT_KEY} "${PRODUCT_UNINST_KEY}" "UninstallString" "$INSTDIR\Ratgeber compact deinstallieren.exe"
WriteRegStr ${PRODUCT_UNINST_ROOT_KEY} "${PRODUCT_UNINST_KEY}" "DisplayIcon" "$INSTDIR\Ratgeber compact starten.exe"
WriteRegStr ${PRODUCT_UNINST_ROOT_KEY} "${PRODUCT_UNINST_KEY}" "Publisher" "${PRODUCT_PUBLISHER}"
SectionEnd


Function un.onUninstSuccess
HideWindow
MessageBox MB_ICONINFORMATION|MB_OK "$(^Name) wurde erfolgreich von Ihrem System entfernt."
FunctionEnd

Function un.onInit
MessageBox MB_ICONQUESTION|MB_YESNO|MB_DEFBUTTON2 "Sind Sie sicher, dass Sie $(^Name) deinstallieren möchten?" IDYES +2
Abort
FunctionEnd

Section Uninstall
Delete "$INSTDIR\"
Delete "$INSTDIR\Ratgeber compact deinstallieren.exe"
Delete "$INSTDIR\Ratgeber compact starten.exe"
Delete "$INSTDIR\rc_laptops_v3.swf"
Delete "$INSTDIR\installer.nsi"


Delete "$SMPROGRAMS\${PRODUCT_KEYNAME}\${PRODUCT_APPNAME}\Ratgeber compact Computer deinstallieren.lnk"
Delete "$SMPROGRAMS\${PRODUCT_KEYNAME}\${PRODUCT_APPNAME}\Ratgeber compact Computer starten.lnk"
Delete "$DESKTOP\Ratgeber compact Computer starten.lnk"

RMDir "$SMPROGRAMS\${PRODUCT_KEYNAME}\${PRODUCT_APPNAME}"
RMDir "$INSTDIR\${PRODUCT_KEYNAME}\${PRODUCT_APPNAME}\pdf\"
RMDir "$INSTDIR\${PRODUCT_KEYNAME}\${PRODUCT_APPNAME}\acrobat reader\"
RMDir "$INSTDIR\${PRODUCT_KEYNAME}\${PRODUCT_APPNAME}\inhalt\"
RMDir /r "$INSTDIR"

DeleteRegKey ${PRODUCT_UNINST_ROOT_KEY} "${PRODUCT_UNINST_KEY}"
DeleteRegKey HKLM "${PRODUCT_DIR_REGKEY}"
SetAutoClose true
SectionEnd


Thanks to all those who try to help me. As said i really have not much time to get this problem solved, so im thankfull for every answer. :)

Greetings
Thalos


Hmm, after some testing i still got that kind of problem.
I searched the forums und modified my script with some extra commands like "CRCCheck off" and "SetCompress off" which speed up the initialisation of the installer under Windows XP massivly, but in Windows Vista it still hangs. When i insert the cd it needs 3-5 minutes until the autostart dialog prompts up. Is there a way to speed up this check up?

I tested variuos other application installtations in vista and the initialisation of the cd's is much faster as with my cd.

Thanks4Help


Here again my actual Script. Did some changes but the Initilization of the CD in Vista still is a problem.


Looks like you're not the first person with this problem:
http://forums.winamp.com/showthread....light=vista+cd

Basically I think your option is not to compress the files in your installer, but have them uncompressed on the CD. You can copy them off using CopyFiles.

Stu


Hey Afro UK,

first of all, thanks for ur answer! :)
I searched the forums and found this thread too, but im a beginner in NSIS scripting, so i would really appreciate it if u could help me to bring this CopyFiles command into my script :)

I modified my Script again and set the

CRCCheck off
SetCompress auto
RequestExecutionLevel Admin

at the beginning of my script.
So Data is now compressed but still in Windows Vista it takes a minute of two till the Autostart-Dialog prompts up where i decide to run the "ratgeber_setup.exe". After this everything works fine. But i dont want the user to wait 1-2 minutes...

If the CopyFiles command would help to solve this problem, you are my hero of the day :)

I searched the Scripting Reference DB for this command, but the information there doesnt give me information about where to put this in my actual script and what command type i should use.

So could you help me plz? Where should i put this peace of code in my script?

Thx4Help


In a Section; same place where you'd normally have your File instructions.

Stu