;; *********************************************************************** ;; *** Grolier NGME Windows Version 6 Installation Script ;; *** (c) 1993 Online Computer Systems, Inc. ;; *** All Rights Reserved. ;; *** ;; *** Special version for Creative Labs' Sound Blaster boards ;; *** Halts installation if Sound Blaster not found in SYSTEM.INI ;; *** ;; *** ;; *** Installation Builder ;; *** Instalit 4.03W ;; *** (c) 1986-92 HPI. All Rights Reserved ;; *** ;; *** Author: Susan Dorsey ;; *** ;; *** Modification History ;; *** 1992 - First Version ;; *** 8/93 - Second Version, major bug fixes ;; *** 9/93 - Third Version, changes requested by client and ;; fix delete files bug ;; ;; 12/21/93 version 6.0.2 modification for NGMEB (HMM/GEP) ;; *********************************************************************** ;; *********************************************************************** ;; *** Constant Declarations ;; *********************************************************************** ;; *********************************************************************** ;; *** Variable Declarations ;; *********************************************************************** DefineVariables Directory [RootDir] := InstallationDrive Logical [CDIdentified] := N Logical [FALSE] := N Logical [No] := N Logical [TRUE] := Y Logical [YesOrNo] := Y Text [AppExe] := NGMEB.EXE Text [AppHelp] := NGMEB.HLP Text [AppName] := NGMEB Text [BGBitmap] := NGMEB.bmp Text [CDDrive] Text [ContainerDir] Text [ContainerDisk] Text [DBName] := groft.win Text [InitFile] := NGMEB.INI Text [NewVersion] := ProductVersion Text [Title] := The New Grolier Multimedia Encyclopedia Text [UserVersion] := ProductVersion EndDefineVariables ;; *********************************************************************** ;; *** Setting Up Installation LoadBitMap InstallationDrive: NGMEB.bmp @xy(5,5) ShowBitMap NGMEB.bmp ShowWindow Maximized SetTopLineTo Installing [Title]. (Press Esc to Quit.) Dialog .c Thank you for purchasing [Title]. EndDialog ;; Windows Version Check If WindowsVersion < 3.1 Dialog .c The version of Windows you have is not 3.1. EndDialog SoLong EndIf GetMenuChoice UseHeader "Main Menu" Start installation of encyclopedia. ; Use this choice to perform the installation process. Stop installation of encyclopedia. ; Use this choice to cancel the installation process. EndGetMenuChoice InCase Choice is =1: Do Install =2: Do CancelInstall EndInCase Do FinishInstall Procedure Install DetermineInstallationDrive 3000000 RequireFixed DisallowNetwork [RootDir] := InstallationDrive:\ [InstallationDirectory] := InstallationDrive:\[AppName] Dialog [InstallationDirectory] 44 UseHeader "Installation Question..." [Title] will copy the necessary files to the directory shown. To accept, press Enter. If you wish to have the necessary files copied to a different directory, please type in the correct information and then press Enter. EndDialog CreateDirectoryIfNecessary [InstallationDirectory] If FileExists [InstallationDirectory]\[AppExe] Dialog [YesOrNo] UseHeader "Installation Question..." .c [Title] has detected an existing copy of the software in the .c [InstallationDirectory] directory. .c Do you wish to continue the installation anyway? EndDialog If [YesOrNo] = N Do CancelInstall Else DeleteFiles from [InstallationDirectory] *.hlp *.exe *.ini eesc.dll EndDeleteFiles EndIf EndIf CopyFiles from [InstallFromDirectory] to [InstallationDirectory] [AppExe] [InitFile] [AppHelp] eesc.dll EndCopyFiles If FileExists [WindowsSystemDirectory]\commdlg.dll [UserVersion] := ProductVersionOf [WindowsSystemDirectory]\commdlg.dll [NewVersion] := ProductVersionOf [InstallFromDirectory]\commdlg.dll If [UserVersion] < [NewVersion] CopyFiles from [InstallFromDirectory] to [WindowsSystemDirectory] COMMDLG.DLL EndCopyFiles EndIf Else CopyFiles from [InstallFromDirectory] to [WindowsSystemDirectory] COMMDLG.DLL EndCopyFiles EndIf SetFileAttrTo 00 for [InstallationDirectory]\[AppExe] SetFileAttrTo 00 for [InstallationDirectory]\[InitFile] SetFileAttrTo 00 for [InstallationDirectory]\[AppHelp] SetFileAttrTo 00 for [InstallationDirectory]\eesc.dll SetFileAttrTo 00 for [WindowsSystemDirectory]\commdlg.dll [CDDrive] := [InstallFromDrive] ;; initialize the cd drive setting [CDIdentified] := N ;; set found flag to no :SearchForCD Dialog [CDDrive] 1 ;; ask user to change cd drive setting if necessary .c Please indicate the CD-ROM drive letter .c where [Title] compact disc will be located. EndDialog If FileExists [CDDrive]:\groft.win ;; validate that cd drive setting is correct [CDIdentified] := Y ;; resets found flag to yes Else GoTo SearchForCD EndIf ;; *** Setup win.ini file with the approriate startup directory [Array1][1] := [AppName] [Array1][2] := dir [Array1][3] := [InstallationDirectory] WriteProfileString Using [Array1] ;; *** Setup disk to get database from [Array1][1] := Database [Array1][2] := Disk [Array1][3] := [CDDrive] [Array1][4] := [InstallationDirectory]\[InitFile] WritePrivateProfileString Using [Array1] ;; *** Setup help directory [Array1][1] := Database [Array1][2] := Help [Array1][3] := [InstallationDirectory]\[AppHelp] [Array1][4] := [InstallationDirectory]\[InitFile] WritePrivateProfileString Using [Array1] ;; *** Setup notes directory [Array1][1] := Database [Array1][2] := Notes [Array1][3] := [InstallationDirectory] [Array1][4] := [InstallationDirectory]\[InitFile] WritePrivateProfileString Using [Array1] ;; *** Installing the Audio [Number9] := 0 Dialog [YesOrNo] UseHeader "Installation Question..." Do you have a Windows-supported sound card installed in your computer? EndDialog If [YesOrNo] = Y Dialog [YesOrNo] UseHeader "Installation Question..." Do you want [Title] to use the card? EndDialog EndIf If [YesOrNo] = Y [Number9] := 1 EndIf If [YesOrNo] = N [Number9] := 0 Dialog PressAKey UseHeader "Installation Message..." Audio not installed for [Title]. Press OK to continue. EndDialog EndIf If [Number9] = 0 [Array1][1] := Database [Array1][2] := RedBook [Array1][3] := 1 [Array1][4] := [InstallationDirectory]\[InitFile] WritePrivateProfileString Using [Array1] EndIf ;; *** Installing the Video Dialog [YesOrNo] UseHeader "Installation Question..." .c Do you want to install Microsoft Video? EndDialog If [YesOrNo] = Y ;; directory name change here!!! (HMM/GEP) Run [InstallFromDirectory]\0MSVIDEO\setup.exe Else Dialog PressAKey UseHeader "Installation Message..." Microsoft Video not installed. Press OK to continue. EndDialog EndIf ;; *** Building Windows Program Manager Group Dialog [YesOrNo] UseHeader "Installation Question..." .c Would you like to build an [AppName] program group? EndDialog If [YesOrNo] = N Do FinishInstall Else PopUp Building NGME Program Group. [Array1][1] := [InstallationDirectory]\[AppExe] BuildProgramGroup "NGME" NGMEB.grp [Array1][1] "Grolier Multimedia Encyclopedia" [Array1][1] EndBuildProgramGroup EndIf EndProcedure ;; *** Canceling an Installation Procedure CancelInstall Dialog [YesOrNo] UseHeader "Installation Question..." Are you sure you want to cancel the installation? EndDialog If [YesOrNo] = N Do Install Else SoLong EndIf EndProcedure ;; *** Install Successfully Finished Procedure FinishInstall Dialog PressAnyKey .c [Title] successfully installed. .c Please call (800) 285-4534 to register [Title]. .c For technical support, call (415) 883-5157. EndDialog SoLong EndProcedure Procedure ByeBye Popup [Title] was not successfully installed Dialog PressAKey WhiteOnBrown .c Thank You for Purchasing [Title]. .c For technical support, call (415) 883-5157. EndDialog SoLong EndProcedure EndScript