First step:
It's about these 6 scripts (3 batch files which trigger 3 corresponding 3 kix files:
step 1:
OutlookInstall.bat
content:
kix32.exe %0\..\OutlookInstall.kix
OutlookInstall.kix
content:
BREAK ON
; Is there an alternative installdirectory?
$Installdir = ReadProfileString("%0\..\OutlookInstall.ini", "InstallDirectory", "dir")
If LEN($Installdir) > 0
$InstallDrive = Substr($Installdir, 1, 3)
; Is there enough on disk ( > 160000 KB)?
$Result = Getdiskspace( $InstallDrive )
If $Result < 160000
goto FOUT
EndIf
; If there is an alternative installdirectory, use it to create an extra commandline option.
$Directory = ' INSTALLLOCATION="' + $InstallDir + '" '
Else
; Is there enough on disk ( > 160000 KB)?
$Result = Getdiskspace( "C:\" )
If $Result < 160000
goto FOUT
EndIf
; No extra commandline option is needed.
$Directory = ""
EndIf
; installation of Outlook
; Determine OS version
$OS = @INWIN
; Determine driveletter of installationsource
; $Drive = Substr(@CURDIR, 1, 2)
$Scriptspath = @CURDIR
; Build the install instruction depending on the OS version.
if $OS = 1 ; Windows NT
$install = $Scriptspath + '\setupprm.exe TRANSFORMS="' + $Scriptspath + '\Ing\Mst\OutlookPremium.mst"' + $Directory + ' /qn'
; $install = $Scriptspath + '\setupprm.exe TRANSFORMS="' + $Scriptspath + '\Ing\Mst\OutlookPremiumNoIE.mst"' + $Directory + ' /qn'
else ; Windows 9x
$install = $Scriptspath + '\setupprm.exe TRANSFORMS="' + $Scriptspath + '\Ing\Mst\W98OutlookPremium.mst"' + $Directory + ' /qn'
endif
;Start the actual installation
Shell $install
; Code to write ING-Version to the registry. Version is kept in the file 'Version.ini'
; in the root of the CD or installation share.
$Version = ReadProfileString ($Scriptspath + "\Version.ini", "Outlook2000", "Version")
$x = AddKey ("HKEY_LOCAL_MACHINE\Software\Ing")
$x = AddKey ("HKEY_LOCAL_MACHINE\Software\Ing\SoftDist")
$x = AddKey ("HKEY_LOCAL_MACHINE\Software\Ing\SoftDist\Outlook2000")
$x = WriteValue("HKEY_LOCAL_MACHINE\Software\Ing\SoftDist\Outlook2000", "Version", $Version, "REG_SZ")
; Code to display some kind of progress indicator to show that install is still running.
Dim $Progress[4]
$Progress[0] = "-"
$Progress[1] = "\"
$Progress[2] = "|"
$Progress[3] = "/"
$Tel = 0
:WaitForReboot
; This part will only stop when a reboot occurs or after we waited 10 minutes
If $Counter > 600 ; we waited 600 * 1 second = 10 minutes
Goto END
Endif
cls
$Tel = $Tel + 1
if $Tel = 4
$Tel = 0
EndIf
?
?
? " Now installing Outlook 2000."
? " Please wait for a reboot."
?
? " Installing: " + $Progress[$Tel]
$Counter = $Counter + 1
Sleep 1
Goto WaitForReboot
:FOUT
? "****************************************************************************"
? "* *"
? "* This workstation has not enough space available to install Outlook 2000. *"
? "* 160 Mb is needed to install. Free some space and try again. *"
? "* *"
? "****************************************************************************"
:END
Cls
?
? " Ten minutes have passed since the installation was started."
? " The installation should be finished by now. Probably there "
? " was no need for a reboot. "
?
? " Please check if the installation process has finished. Use the Task Manager "
? " to see if there is just one process called 'msiexec.exe'. If there are three "
? " processes called 'msiexec.exe', than the installation is not finished. "
?
? " Press any key to close this window... "
Get $x