| ;;++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
;;
;; Copyright (C) 1992, 1993, 1994, 1995 by
;; Digital Equipment Corporation, Maynard, MA.
;; All Rights Reserved
;;
;; This software is furnished under a license and may be used and copied
;; only in accordance with the terms of such license and with the
;; inclusion of the above copyright notice. This software or any other
;; copies thereof may not be provided or otherwise made available to any
;; other person. No title to and ownership of the software is hereby
;; transferred.
;;
;; The information in this software is subject to change without notice
;; and should not be construed as a commitment by Digital Equipment
;; Corporation.
;;
;; Digital assumes no responsibility for the use or reliability of its
;; software on equipment which is not supplied by Digital.
;;
;; **************************************
;; This script defines the HUBwatch 4.0 installation procedure
;; for Windows. This script is written for using INSTALIT - an
;; installation tool provided by HPI.
;; **************************************
;;
;; AUTHORS:
;; V1.0 Susan Livsey
;;
;; CREATION DATES:
;; V1.0 January 1994
;;
;; NOTE:
;; This script was modified by Carlos Silva to make the HW
;; installation work in the Spanish version of MS Windows
DefineVariables
Text [ProductName] := HUBwatch
Text [HUBwatchProductName] := HUBwatch for Windows
Text [ExecutableName] := HUBWATCH.EXE
Text [ProductRequiredFile] := HUBWATCH.EXE
Text [ProductVersion] := V4.1.1
Text [DefaultProductDirectory] := \HUBWATCH
Text [SubdirectoryName] := USERDATA
Text [OVSubdirectoryName] := HUBWOV
Text [OVAppName] := HUBwov
Text [OVAppVersion] := C0.1
;; SLL 11/30/94 Add NMS support
Text [NMSSubdirectoryName] := HUBWNMS
Text [NetworkSubdirectoryName] := IPSTACK
Text [SubdirectoryPath]
;;BEWC 7/26/94 Add HUBwatch section and path in WIN.INI
Text [HUBwatchSection] := [HUBwatch]
Text [HUBwatchPath] := HUBwatchPath
;; BEWC 2/23/95 Add ManageWORKS subdirectory
Text [MWORKSProductName] := Digital ManageWORKS Workgroup Administrator
Text [PATHWORKSProductName] := PATHWORKS
Text [MWORKSSubdirectoryName] := HUBWMWRK
Number [MW_files] := 0
Number [MW_flag] := 0
Number [PW_files] := 0
Number [PW_flag] := 0
Number [NoVerifyFlag] := 0
Text [MWORKS_path]
Text [MWORKS_drive]
Text [HUBW_MWORKS_path]
Text [PATHWORKS_path]
Text [PATHWORKS_path2]
Text [PATHWORKS_drive]
;; BEWC 4/14/95 Add WFW vs. Windows
Text [WFW_protocol_path]
;; BEWC 5/2/95 Add to WFW vs. Windows
Number [WFW_flag] := 0
;;SLL 11/23/94 Add HUBload
Text [SubProductName] := HUBloader
Text [SubExecutableName] := HUBLOAD.EXE
Text [SubProductRequiredFile] := HUBLOAD.EXE
Text [DefaultSubProductDirectory] := \HUBLOAD
;; BEWC 2/17/95 for \netrider\load\loader.exe for Icon
Text [SubProductSub_Executable] := \NETRIDER\LOAD\LOADER.EXE
Text [NetriderLoadIcon] := TFTP_Server
;;BEWC 2/15/95 Remove EZLOAD and add \NETRIDER\LOAD
Text [SubProdSubDir] := \NETRIDER\LOAD
Text [HUBloadSection] := [HUBload]
Text [HUBloadPath] := HUBloadPath
Text [NETRSubProductName] := NETrider Loader
;; BEWC 3/30/95 Remove HUBWATCH_SYSTEM environment variable
Text [HUBWATCH_SYSTEM_string]
Logical [EditAutoexec] := NoCharacter
;; strings to contain drive and directory settings
Text [PWInstallDir]
Text [PWInstallDrive]
Text [PWInstallNoDrive]
Text [ProductInstallDrive]
Text [ProductInstallDir]
Text [SubProductInstallDir]
;; colors for various windows
Text [PopupColors] := WhiteOnBlue
Text [AttentionColors] := BlackonYellow
Text [SpecialPopupColors] := WhiteOnBlue
Text [ScreenColors] := WhiteOnBlue
;; configuration requirements
Text [MinimumOSVersion] := 5.0
Logical [AllowCGA] := YesCharacter
Logical [AllowMDA] := YesCharacter
Logical [Allow808x] := YesCharacter
Logical [Allow80286] := YesCharacter
Logical [MathCoprocessorRecommended] := NoCharacter
Text [NetworkInstallation] := AllowNetwork
Text [TopLine] := " [ProductName] [ProductVersion], (c) Copyright 1992, 1995 Digital Equipment Corporation "
;; actual configuration
Text [DisplayAdapterSummary]
Text [CPUTypeSummary]
Text [NetworkActive]
Text [MathCoprocessorStatus]
Text [OSVersionSummary]
Text [SystemMemorySummary]
Logical [InsufficientSystem] := NoCharacter
;; miscellaneous
Text [Product_Executable]
;; SLL 11/30/94 for HUBload
Text [SubProduct_Executable]
Text [GroupTitle]
Text [WinsockPath]
Logical [NetworkFilesFound]
Logical [copy_nms_files]
Text [OVIniFile]
Text [OVDir]
;; SLL 11/30/94 for NMS support
Text [NMSOlfPath]
Text [NMSDllPath]
Text [NMSIconPath]
Text [NMSHelpPath]
Text [PathForBackup]
Text [FileForBackup]
Text [BackupFileName]
Logical [Finished] := NoCharacter
Logical [Figged] := NoCharacter
Logical [CompatibilityNoticeGiven] := NoCharacter
Logical [DoNetworkInstall]
Logical [StopInstall] := NoCharacter
Logical [DoBothEnvVariables]
Number [MainChoice] := 1
Number [Choice1]
;; used for configuring network
Text [HostIP]
Text [SubNet]
Text [GateIP]
Text [Usrnam]
Text [NamePC]
Text [DnsIP]
Text [Domain]
Text [ewrk3_rem]
Text [depca_rem]
Text [DriverName] := _______
;; BEWC 8/16/94 add Other MAC drivers support
Text [smcmac_rem]
Text [elnkii_rem]
Text [elnkpl_rem]
Text [elnk3_rem]
Text [i82593_rem]
Text [exp16_rem]
Text [FullNetworkString]
Text [VpktdrvrString]
Text [NetworkString]
Text [NetworkRemark]
Text [ewrk3_string]
Text [depca_string]
;; BEWC 8/16/94 add Other MAC drivers support
Text [smcmac_string]
Text [elnkii_string]
Text [elnkpl_string]
Text [elnk3_string]
Text [i82593_string]
Text [exp16_string]
;; BEWC 2/21/95 add DEFEA driver NDIS support only
Text [defea_rem]
Text [defea_string]
Text [ProtoFile]
Text [ProtoFileExt]
Text [ProtoFileTemplate]
Text [StartFile]
Text [ConfigFile]
Text [SystemFile]
Logical [EditSystemIni]
Text [AutoFile]
Number [NetType]
Logical [EditConfig]
Number [NetworkType]
Number [NetworkCard]
EndDefineVariables
;;----------------------------------------------------------------------
;; setup strtndis.bat, strtodi.bat, strtslip.bat
;;----------------------------------------------------------------------
Procedure SetupStartFile
;; REMOVED odi -- if/when reactivated, set [NetworkType] := 3 for odi
;; GetMenuChoice DisallowIfNone Highlight 1 UseHeader "Type of Network"
;; NDIS network [NetworkType] := 1
;; ; To set up NDIS and SLIP services
;; ODI network [NetworkType] := 3
;; ; To set up ODI and SLIP services
;; SLIP only [NetworkType] := 2
;; ; To set up SLIP services only
;; EndGetMenuChoice
GetMenuChoice DisallowIfNone Highlight 1 UseHeader "Type of Network"
NDIS network and SLIP
; To set up NDIS and SLIP services
SLIP only
; To set up SLIP services only
EndGetMenuChoice
InCase choice is
=1: [NetworkType] := 1
[NetType] := 0;
=2: [NetworkType] := 2
[NetType] := 2;
;;ODI =3: [NetworkType] := 3
EndInCase
;; set the NetworkType in pwtcp.ini
;; this could have been done in SetConfigParams, but that would
;; require calling this procedure first. Since the documentation
;; is already written for this order...
ModifyTextFile [PWInstallDir]\pwtcp.ini Quietly
InSection [TCPIP]
AddOrChangeLineWith (NetworkType,=,) as "NetworkType = [NetType] ; 0 = Ethernet or Token Ring or Mobile" At Beginning
EndModifyTextFile
;; set the appropriate fields in strtslip.bat
ModifyTextFile [PWInstallDir]\strtslip.bat Quietly
DeleteLine 2
InsertAtLine 2 [PWInstallDrive]
DeleteLine 3
InsertAtLine 3 cd [PWInstallNoDrive]
AddOrChangeLineWith (path,oldpath,bat) as "path >[PWInstallDir]\oldpath.bat" At Beginning
AddOrChangeLineWith (echo,set,path) as "echo set path=>[PWInstallDir]\oldpath.bat,[WindowsDirectory]" At Beginning
AddOrChangeLineWith (set PCSA,=,) as "set PCSA=[PWInstallDir]" At Beginning
EndModifyTextFile
;;set the appropriate fields in stopnet.bat (backing up existing file)
ModifyTextFile [PWInstallDir]\stopnet.bat Quietly
AddOrChangeLineWith (oldpath,bat,) as "if exist [PWInstallDir]\oldpath.bat call [PWInstallDir]\oldpath.bat" At End
EndModifyTextFile
If [NetworkType] = 2 ;;Slip only, done above
[StartFile] := "STRTSLIP.BAT"
Goto ExitSetupStartFile
EndIf
;; BEWC 8/16/94 add Other MAC drivers support
[Number2] := 10 ;;Highlight Other ;BEWC 3/22/95 Other
If [NetworkType] = 1 ;;NDIS
ExamineTextFile [PWInstallDir]\strtndis.bat
[String1] := LineWith (ld,ewrk3,dos)
[Number1] := PositionOf "REM" in [String1]
If [Number1] = 0
[Number2] := 1
EndIf
[String1] := LineWith (ld,depca,dos)
[Number1] := PositionOf "REM" in [String1]
If [Number1] = 0
[Number2] := 2
EndIf
[String1] := LineWith (ld,defea,dos)
[Number1] := PositionOf "REM" in [String1]
If [Number1] = 0
[Number2] := 3
EndIf
[String1] := LineWith (ld,smcmac,dos)
[Number1] := PositionOf "REM" in [String1]
If [Number1] = 0
[Number2] := 4
EndIf
[String1] := LineWith (ld,elnkii,dos)
[Number1] := PositionOf "REM" in [String1]
If [Number1] = 0
[Number2] := 5
EndIf
[String1] := LineWith (ld,elnkpl,dos)
[Number1] := PositionOf "REM" in [String1]
If [Number1] = 0
[Number2] := 6
EndIf
[String1] := LineWith (ld,elnk3,dos)
[Number1] := PositionOf "REM" in [String1]
If [Number1] = 0
[Number2] := 7
EndIf
[String1] := LineWith (ld,i82593,dos)
[Number1] := PositionOf "REM" in [String1]
If [Number1] = 0
[Number2] := 8
EndIf
[String1] := LineWith (ld,exp16,dos)
[Number1] := PositionOf "REM" in [String1]
If [Number1] = 0
[Number2] := 9
EndIf
[Number3] := LineNumberWith (ld,exp16,dos)
IncrementNumber [Number3]
ForgetTextFile ;; Close strtndis.bat
[ProtoFileExt] := "PROTOCOL.INI"
[ProtoFile] := "protocol"
[ProtoFileTemplate] := "pro"
[StartFile] := "STRTNDIS.BAT"
else ;;ODI
;; REMOVED -- note that we can not get here for now
ExamineTextFile [PWInstallDir]\strtodi.bat
[String1] := LineWith (ld,ewrk3,com)
[Number1] := PositionOf "REM" in [String1]
If [Number1] = 0
[Number2] := 1
EndIf
[String1] := LineWith (ld,depca,com)
[Number1] := PositionOf "REM" in [String1]
If [Number1] = 0
[Number2] := 2
EndIf
;; BEWC 8/16/94 add Other MAC drivers support
[String1] := LineWith (ld,elnkii,com)
[Number1] := PositionOf "REM" in [String1]
If [Number1] = 0
[Number2] := 4
EndIf
[String1] := LineWith (ld,elnkpl,com)
[Number1] := PositionOf "REM" in [String1]
If [Number1] = 0
[Number2] := 5
EndIf
[Number3] := LineNumberWith (ld,exp16,com)
IncrementNumber [Number3]
ForgetTextFile ;; Close strtodi.bat
[ProtoFileExt] := "NET.CFG"
[ProtoFile] := "net"
[ProtoFileTemplate] := "nc"
[StartFile] := "STRTODI.BAT"
EndIf ;;ODI
;; BEWC 8/16/94 add Other MAC drivers support
GetMenuChoice DisallowIfNone Highlight [Number2] UseHeader "Type of Network Card"
Digital EtherWORKS 3 network card
Digital Ethernet (DEPCA) network card
;; BEWC 2/21/95 add DEFEA driver NDIS support only
Digital FDDIcontroller/EISA (DEFEA) network card
SMC EtherCard PLUS Elite16 (SMCMAC) network card
3COM EtherLink II Adapter (3c503) network card
3COM EtherLink Plus Adapter (3c505-B) network card
3COM EtherLink III Adapter (3c509) network card
Intel 82593 Demo Card (I82593) network card
Intel Ether Express 16 Adapter (Exp16) network card
Other
EndGetMenuChoice
;; BEWC 8/16/94 add Other MAC drivers support
InCase choice is
=1: [NetworkCard] := 1 ;;EWRK3
=2: [NetworkCard] := 2 ;;DEPCA
;; BEWC 2/21/95 add DEFEA driver NDIS support only
=3: [NetworkCard] := 3 ;;DEFEA
=4: [NetworkCard] := 4 ;;SMCMAC
=5: [NetworkCard] := 5 ;;ELNKII
=6: [NetworkCard] := 6 ;;ELNKPL
=7: [NetworkCard] := 7 ;;ELNK3
=8: [NetworkCard] := 8 ;;I82593
=9: [NetworkCard] := 9 ;;EXP16
=10: [NetworkCard] := 10 ;;Other
;;BEWC 8/16/94 NOTE Other was = 3 now should be 9; 2/21/95 now should be 10
EndInCase
;; if 'Other' network card, ask for the driver and configuration
;; files
[String4] := " "
If [NetworkCard] = 10 ;;Other Network Card
:get_driver
[String4] := "A:\"
[String5] := BlankString
;; BEWC 9/23/94 add more description to text fields on Other driver input dialog
DialogBox 200 126 UseHeader "Network Card Adapter Driver Info" BlackOnLightGray Returns [Number7]
;; CText @xy(2,10) 200 8 "**Refer to your Vendor's Driver Installation Instructions.**"
LText @xy(22,30) 200 8 "Enter the Vendor supplied Network Driver diskette"
LText @xy(22,40) 200 8 "Path OR Local Path for the Driver location."
LText @xy(27,50) 125 8 "Syntax: DRIVE:\DIRECTORY"
EditText @xy(12,50) 200 8 Uses [String4]
LText @xy(22,70) 200 8 "Enter the Vendor Network Adapter Driver Name."
LText @xy(27,80) 130 8 "Syntax: DRIVERNAME.EXTENSION"
EditText @xy(145,80) 100 8 Uses [DriverName]
PushButton @xy(40,100) 38 14 "OK" OK
PushButton @xy(122,100) 38 14 "CANCEL" 100
EndDialogBox
;; EditText @xy(145,80) 100 8 Uses [String5]
[String5] := [DriverName]
If (Escaped) .OR. ([Number7] = 100)
[StopInstall] := YesCharacter
Goto ExitSetupStartFile
else
If FileExists [String4]\[String5]
If FileExists [String4]\[ProtoFileExt]
EndIf
else
PopUp Could not locate driver and/or Vendor supplied PROTOCOL.INI file.
Goto get_driver
EndIf
EndIf
EndIf
;; back up protocol.ini or net.cfg, if it exists
;; BackupNameFor does not seem to work....
If FileExists [PWInstallDir]\[ProtoFileExt]
[FileForBackup] := [ProtoFile]
[PathForBackup] := [PWInstallDir]
Do MyBackupNameFor
CopyFiles from [PWInstallDir] to [PWInstallDir] quietly
[ProtoFileExt] as [BackupFileName]
EndCopyFiles
EndIf
;; copy the appropriate protocol file to protocol.ini
;; or configuration file to net.cfg
;; BEWC 8/16/94 add Other MAC drivers support
[ewrk3_rem] := "REM "
[depca_rem] := "REM "
;; BEWC 2/21/95 add DEFEA driver NDIS support only
[defea_rem] := "REM "
[smcmac_rem] := "REM "
[elnkii_rem] := "REM "
[elnkpl_rem] := "REM "
[elnk3_rem] := "REM "
[i82593_rem] := "REM "
[exp16_rem] := "REM "
If [NetworkCard] = 1 ;;EWRK3
[ewrk3_rem] := BlankString
CopyFiles from [PWInstallDir] to [PWInstallDir] quietly
ewrk3.[ProtoFileTemplate] as [ProtoFileExt]
EndCopyFIles
else
If [NetworkCard] = 2 ;;DEPCA
[depca_rem] := BlankString
CopyFiles from [PWInstallDir] to [PWInstallDir] quietly
depca.[ProtoFileTemplate] as [ProtoFileExt]
EndCopyFIles
else
;; BEWC 2/21/95 add DEFEA driver NDIS support only
If [NetworkCard] = 3 ;;DEFEA
[defea_rem] := BlankString
CopyFiles from [PWInstallDir] to [PWInstallDir] quietly
defea.[ProtoFileTemplate] as [ProtoFileExt]
EndCopyFIles
else
;; BEWC 8/16/94 add Other MAC drivers support
If [NetworkCard] = 4 ;;smcmac
[smcmac_rem] := BlankString
CopyFiles from [PWInstallDir] to [PWInstallDir] quietly
smcmac.[ProtoFileTemplate] as [ProtoFileExt]
EndCopyFIles
else
If [NetworkCard] = 5 ;;elnkii
[elnkii_rem] := BlankString
CopyFiles from [PWInstallDir] to [PWInstallDir] quietly
elnkii.[ProtoFileTemplate] as [ProtoFileExt]
EndCopyFIles
else
If [NetworkCard] = 6 ;;elnkpl
[elnkpl_rem] := BlankString
CopyFiles from [PWInstallDir] to [PWInstallDir] quietly
elnkpl.[ProtoFileTemplate] as [ProtoFileExt]
EndCopyFIles
else
If [NetworkCard] = 7 ;;elnk3
[elnk3_rem] := BlankString
CopyFiles from [PWInstallDir] to [PWInstallDir] quietly
elnk3.[ProtoFileTemplate] as [ProtoFileExt]
EndCopyFIles
else
If [NetworkCard] = 8 ;;i82593
[i82593_rem] := BlankString
CopyFiles from [PWInstallDir] to [PWInstallDir] quietly
i82593.[ProtoFileTemplate] as [ProtoFileExt]
EndCopyFIles
else
If [NetworkCard] = 9 ;;exp16
[exp16_rem] := BlankString
CopyFiles from [PWInstallDir] to [PWInstallDir] quietly
exp16.[ProtoFileTemplate] as [ProtoFileExt]
EndCopyFIles
else
If [NetworkCard] = 10 ;;Other Network Card
CopyFiles from [String4] to [PWInstallDir] quietly
[ProtoFileExt] as [ProtoFile].nic
[String5]
EndCopyFiles
[String4] := "ld [String5]"
EndIf ;;End option 10
EndIf ;;End option 9
EndIf ;;End option 8
EndIf ;;End option 7
EndIf ;;End option 6
EndIf ;;End option 5
EndIf ;;End option 4
EndIf ;;End option 3
EndIf ;; End option 2
EndIf ;; End option 1
If [NetworkType] = 1 ;;NDIS and Slip
;; set the appropriate fields in strtndis.bat
ModifyTextFile [PWInstallDir]\strtndis.bat Quietly
DeleteLine 2
InsertAtLine 2 [PWInstallDrive]
DeleteLine 3
InsertAtLine 3 cd [PWInstallNoDrive]
AddOrChangeLineWith (path,oldpath,bat) as "path >[PWInstallDir]\oldpath.bat" At Beginning
AddOrChangeLineWith (echo,set,path) as "echo set path=>[PWInstallDir]\oldpath.bat,[WindowsDirectory]" At Beginning
AddOrChangeLineWith (set PCSA,=,) as "set PCSA=[PWInstallDir]" At Beginning
AddOrChangeLineWith (ld,protman.dos,) as "ld protman.dos /i:[PWInstallDir]" At Beginning
AddOrChangeLineWith (ld,ewrk3.dos,) as "[ewrk3_rem]ld ewrk3.dos" At Beginning
AddOrChangeLineWith (ld,depca.dos,) as "[depca_rem]ld depca.dos" At Beginning
;; BEWC 2/21/95 add DEFEA driver NDIS support only
AddOrChangeLineWith (ld,defea.dos,) as "[defea_rem]ld defea.dos" At Beginning
;; BEWC 8/16/94 add Other MAC drivers support
AddOrChangeLineWith (ld,smcmac.dos,) as "[smcmac_rem]ld smcmac.dos" At Beginning
AddOrChangeLineWith (ld,elnkii.dos,) as "[elnkii_rem]ld elnkii.dos" At Beginning
AddOrChangeLineWith (ld,elnkpl.dos,) as "[elnkpl_rem]ld elnkpl.dos" At Beginning
AddOrChangeLineWith (ld,elnk3.dos,) as "[elnk3_rem]ld elnk3.dos" At Beginning
AddOrChangeLineWith (ld,i82593.dos,) as "[i82593_rem]ld i82593.dos" At Beginning
AddOrChangeLineWith (ld,exp16.dos,) as "[exp16_rem]ld exp16.dos" At Beginning
InsertAtLine [Number3] [String4]
EndModifyTextFile
else ;;ODI
;; set the appropriate fields in strtodi.bat
;; REMOVED -- note that we can not get here for now
ModifyTextFile [PWInstallDir]\strtodi.bat Quietly
DeleteLine 2
InsertAtLine 2 [PWInstallDrive]
DeleteLine 3
InsertAtLine 3 cd [PWInstallNoDrive]
AddOrChangeLineWith (path,oldpath,bat) as "path >[PWInstallDir]\oldpath.bat" At Beginning
AddOrChangeLineWith (echo,set,path) as "echo set path=>[PWInstallDir]\oldpath.bat,[WindowsDirectory]" At Beginning
AddOrChangeLineWith (set PCSA,=,) as "set PCSA=[PWInstallDir]" At Beginning
AddOrChangeLineWith (ld,ewrk3.com,) as "[ewrk3_rem]ld ewrk3.com" At Beginning
AddOrChangeLineWith (ld,depca.com,) as "[depca_rem]ld depca.com" At Beginning
;; BEWC 8/16/94 add Other MAC drivers support
AddOrChangeLineWith (ld,elnkii.com,) as "[elnkii_rem]ld elnkii.com" At Beginning
AddOrChangeLineWith (ld,elnkpl.com,) as "[elnkpl_rem]ld elnkpl.com" At Beginning
InsertAtLine [Number3] [String4]
EndModifyTextFile
EndIf ;;else ODI
:ExitSetupStartFile
EndProcedure ;;Procedure SetupStartFile
;;----------------------------------------------------------------------
;; Setup the environment
;;----------------------------------------------------------------------
Do SetupInstalit
;; REMOVED Do PrepareSystemReport
If [Finished] = YesCharacter
Goto Finish
EndIf
;; BEWC 5/11/95 Backup system files to .HUB
If FileExists [BootDrive]:\autoexec.bat
CopyFiles from [BootDrive]:\ to [BootDrive]:\ quietly
AUTOEXEC.BAT as AUTOEXEC.HUB
EndCopyFiles
EndIf
If FileExists [BootDrive]:\config.sys
CopyFiles from [BootDrive]:\ to [BootDrive]:\ quietly
CONFIG.SYS as CONFIG.HUB
EndCopyFiles
EndIf
If FileExists [WindowsDirectory]\WIN.INI
CopyFiles from [WindowsDirectory]\ to [WindowsDirectory]\ quietly
WIN.INI as WIN.HUB
EndCopyFiles
EndIf
If FileExists [WindowsDirectory]\SYSTEM.INI
CopyFiles from [WindowsDirectory]\ to [WindowsDirectory]\ quietly
SYSTEM.INI as SYSTEM.HUB
EndCopyFiles
EndIf
;;----------------------------------------------------------------------
;; Display the welcome message.
;;----------------------------------------------------------------------
Dialog
.cThank you for purchasing Digital's [ProductName] software.
.cThis program installs [ProductName] [ProductVersion] on your PC.
.cSimply follow the instructions and answer the questions
.cwhen prompted by the program.
EndDialog
;;----------------------------------------------------------------------
;; Display the Main Menu
;;----------------------------------------------------------------------
:MainMenu
TextBox @xy(Center,60)
Use the [Up Arrow] and [Down Arrow] keys to move the highlight bar
to the desired operation. Press [Enter] or click on 'OK' to make
your selection. Press [Esc] to stop the installation.
EndTextBox
[AutoFile] := BlankString
[ConfigFile] := BlankString
[SystemFile] := BlankString
[String1] := BlankString
[StopInstall] := NoCharacter
;; BEWC 2/20/95 placed install applications only menu choice as default(top of menu)
GetMenuChoice @xy(Center, 150) DisallowIfNone Highlight [MainChoice] UseHeader "Main Menu"
Install [ProductName], [SubProductName], and [NETRSubProductName] only
;To copy [ProductName], [SubProductName], and [NETRSubProductName] files from diskette to the
;destination directory and set up for [MWORKSProductName],
;HP OpenView or Novell NMS.
Install [ProductName], [SubProductName], [NETRSubProductName] and network
;To copy [ProductName], [SubProductName], [NETRSubProductName] and network files from diskette to
;the destination directory, set up for [MWORKSProductName],
;HP OpenView or Novell NMS, and configure the network.
Install and configure the network
;To copy network files from diskette to the destination
;directory and set network configuration parameters.
Install [ProductName], [SubProductName], and [NETRSubProductName] icons
;To add [ProductName], [SubProductName], and [NETRSubProductName]
;icons to the Program Manager.
Set path to User Data file
;To modify path for [ProductName] user data file.
Set up for [MWORKSProductName]
;To set up [ProductName] to run from [MWORKSProductName].
Set up for HP OpenView
;To set up [ProductName] to run with HP OpenView.
Set up for Novell NMS
;To set up [ProductName] to run with Novell NMS.
Set network configuration parameters
;To modify network parameters for your environment.
Exit
;To exit this procedure.
EndGetMenuChoice
ClearScreen
;; change default to 'Exit'
[MainChoice] := 10
[DoNetworkInstall] := NoCharacter
;; BEWC 2/20/95 placed install applications only menu choice as default(top of menu)
;; 2/9/95 Add set up for HUBwatch to be launched from ManageWORKS
InCase choice is
=1: Do Install
=2: [DoNetworkInstall] := YesCharacter
Do Install
=3: Do InstallNetwork
=4: Do AddToProgramManager
=5: Do GetPath
[DoBothEnvVariables] := NoCharacter
Do SetPathToPrefFiles
=6: Do SetupForMWORKS
=7: Do SetupForOV
=8: Do SetupForNMS
=9: Do Config
=10: Goto Finish
EndInCase
Goto MainMenu
:Finish
;;Exit point. Display the solong message.
;; REMOVED odi (STRTODI.BAT)
If [Figged] = YesCharacter
Dialog PressAnyKey [PopupColors]
.cThe network software is configured and ready to use on
.cyour PC. Run STRTNDIS.BAT to make network connections.
.cOr run STRTSLIP.BAT to start a serial connection.
.cIf your network is currently running, run STOPNET.BAT to stop
.cthe network before running STRTNDIS or STRTSLIP.
EndDialog
EndIf
If FileExists ShadowDirectory\logo.bmp
HideBitMap 1
DeleteFiles from ShadowDirectory
logo.bmp
EndDeleteFiles
EndIf
SoLong
Dialog 2000 [PopupColors]
Exiting installation procedure...
EndDialog
;;---------------------------------------------------------
;; Procedures used within the script
;;---------------------------------------------------------
;;---------------------------------------------------------
;;---------------------------------------------------------
Procedure GetPath
If [ProductInstallDir] <> BlankString
[String2] := [ProductInstallDir]\[SubdirectoryName]
else
[String2] := [BootDrive]:[DefaultProductDirectory]\[SubdirectoryName]
EndIf
DialogBox 177 50 UseHeader "Set path to User Data file" BlackOnLightGray Returns [Number7]
EditText @xy(15,7) 120 14 Uses [String2] AutoHScroll Border UpperCase
PushButton @xy(30,30) 38 14 "OK" OK
PushButton @xy(90,30) 38 14 "CANCEL" 100
EndDialogBox
If (Escaped) .OR. ([Number7] = 100)
[SubdirectoryPath] := BlankString
else
[SubdirectoryPath] := [String2]
EndIf
EndProcedure ;; Procedure GetPath
;;----------------------------------------------------------------------
;; Handle the installation of the kit
;;----------------------------------------------------------------------
Procedure Install
;; queue files so we know how much space we need
QueFileGroup 1 ;; executable and data file
QueFileGroup 2 to [InstallationDirectory]\[SubdirectoryName]
QueFileGroup 3 to [InstallationDirectory]\[OVSubdirectoryName]
;; SLL 11/23/94 -- add HUBload
QueFileGroup 4 to [DefaultSubProductDirectory]
;; BEWC 2/20/95 use this directory for /netrider/load since just checking disk space
QueFileGroup 8 to [DefaultSubProductDirectory]
;; SLL 11/30/94 -- NMS interface
QueFileGroup 9 to [InstallationDirectory]\[NMSSubdirectoryName]
;; BEWC 2/23/95 Add ManageWORKS
QueFileGroup 10 to [InstallationDirectory]\[MWORKSSubdirectoryName]
If [DoNetworkInstall] = YesCharacter
QueFileGroup 5 to [InstallationDirectory]\[NetworkSubdirectoryName]
QueFileGroup 6 to [WindowsDirectory]\system
EndIf
;; Get the target drive and target directory.
Do GetDestinationDrive
;;SLL DetermineInstallationDirectory InstallationDrive:[DefaultProductDirectory]
;; put up the dialog box ourselves, so we can tell the user which
;; directory we're getting
[ProductInstallDir] := InstallationDrive:[DefaultProductDirectory]
DialogBox 220 86 UseHeader "INSTALL" BlackOnLightGray Returns [Number7]
;; CText @xy(5,1) 200 8 "PLEASE CHOOSE YOUR INSTALLATION DIRECTORY FOR"
;; CText @xy(5,11) 200 8 [ProductName]
;; CText @xy(5,21) 200 8 "ON A FIXED DRIVE."
;; CText @xy(5,36) 200 8 "Make your choice and press <Enter> or click on OK."
EditText @xy(10,51) 200 12 Uses [ProductInstallDir] AutoHScroll Border
PushButton @xy(40,70) 38 14 "OK" OK
PushButton @xy(122,70) 38 14 "CANCEL" 100
EndDialogBox
If (Escaped) .OR. ([Number7] = 100)
[StopInstall] := YesCharacter
UnQueAllFiles
Goto ExitInstall
EndIf
[ProductInstallDrive] := InstallationDrive
[InstallationDirectory] := [ProductInstallDir]
;; SLL 11/23/94 -- Get target directory for HUBload
;;DetermineInstallationDirectory InstallationDrive:[DefaultSubProductDirectory]
[SubProductInstallDir] := InstallationDrive:[DefaultSubProductDirectory]
DialogBox 220 86 UseHeader "INSTALL" BlackOnLightGray Returns [Number7]
;; CText @xy(5,1) 200 8 "PLEASE CHOOSE YOUR INSTALLATION DIRECTORY FOR"
;; CText @xy(5,11) 200 8 [SubProductName]
;; CText @xy(5,21) 200 8 "ON A FIXED DRIVE."
;; CText @xy(5,36) 200 8 "Make your choice and press <Enter> or click on OK."
EditText @xy(10,51) 200 12 Uses [SubProductInstallDir] AutoHScroll Border
PushButton @xy(40,70) 38 14 "OK" OK
PushButton @xy(122,70) 38 14 "CANCEL" 100
EndDialogBox
If (Escaped) .OR. ([Number7] = 100)
[StopInstall] := YesCharacter
UnQueAllFiles
Goto ExitInstall
EndIf
;; HUBloader and NetRider
UnQueFileGroup 4
UnQueFileGroup 8
QueFileGroup 4 to [SubProductInstallDir]
QueFileGroup 8 to InstallationDrive:[SubProdSubDir]
;; create subdirectories if necessary
CreateDirectoryIfNecessary [InstallationDirectory]\[SubdirectoryName]
CreateDirectoryIfNecessary [InstallationDirectory]\[OVSubdirectoryName]
;; SLL 11/30/94 -- directory for NMS suppport
CreateDirectoryIfNecessary [InstallationDirectory]\[NMSSubdirectoryName]
;; SLL 11/23/94 -- create directories for HUBload
CreateDirectoryIfNecessary [SubProductInstallDir]
CreateDirectoryIfNecessary InstallationDrive:[SubProdSubDir]
;; BEWC 2/23/95 -- create directory for Digital ManageWORKS support
CreateDirectoryIfNecessary [InstallationDirectory]\[MWORKSSubdirectoryName]
If [DoNetworkInstall] = YesCharacter
CreateDirectoryIfNecessary [InstallationDirectory]\[NetworkSubdirectoryName]
EndIf
;; BEWC 5/11/95 Move textbox to top of the display
TextBox @xy(Center,75)
Copying files from disk...
EndTextBox
CopyFiles from [InstallFromDirectory] to [InstallationDirectory] quietly
read_me.txt
EndCopyFiles
CopyFiles from [InstallFromDirectory] to [SubProductInstallDir] quietly
read_me_.txt
EndCopyFiles
GetQuedFiles
ClearScreen
Dialog PressAnyKey [PopupColors]
.c[ProductName], [SubProductName], and [NETRSubProductName]
.cfiles have been successfully copied to the [InstallationDirectory],
.c[SubProductInstallDir], and InstallationDrive:[SubProdSubDir]
.cdirectories.
EndDialog
If Escaped
Goto ExitInstall
EndIf
Do AddToProgramManager
If [StopInstall] = YesCharacter
Goto ExitInstall
EndIf
[SubdirectoryPath] := [InstallationDirectory]\[SubdirectoryName]
[DoBothEnvVariables] := YesCharacter
Do SetPathToPrefFiles
;; set up for HP OpenView, if it is present
Do SetupForOV
;; set up for NMS, if it is present
Do SetupForNMS
If [DoNetworkInstall] = YesCharacter
Do Config ;; configure the network
Else
Do CheckforPWSetup ;; Check for PATHWORKS V5.1 setup
EndIf
;; Get rid of WINSOCK.DLL in HUBwatch installation directory(default) if exists
If FileExists [InstallationDirectory]\WINSOCK.DLL
DeleteFiles from [InstallationDirectory] Quietly
WINSOCK.DLL
EndDeleteFiles
EndIf
;; BEWC 2/8/95 Add setup for ManageWORKS to launch HUBwatch
;; *** MUST PERFORM SETUP OF MANAGEWORKS AFTER NETWORK ***
Do SetupForMWORKS
:ExitInstall
EndProcedure ;; Procedure Install
;;------------------------------------------------------------------------------
;; Check for PATHWORKS TCPIP V5.1 in Path Statement and/or all fixed disks.
;; If exist, update UDPMaxSock in PWTCP.INI.
;;------------------------------------------------------------------------------
Procedure CheckforPWSetup
;; Check for PATHWORKS in Path
[PATHWORKS_path] := FullPathTo PWTCP.INI PathOnly
;; If no PATHWORKS path found
If [PATHWORKS_path] = BlankString
;; Check for PATHWORKS directory on all devices
ClearScreen
;; BEWC 5/11/95 Move textbox to top of the display
TextBox @xy(Center,75)
Searching for [PATHWORKSProductName] on all devices...
EndTextBox
[PATHWORKS_path] := FullPathTo PWTCP.INI Search AllFixed
;; If no PATHWORKS path found
If [PATHWORKS_path] = BlankString
Goto ExitCheckforPWSetup
EndIf
EndIf
;; Obtain drive letter from PATHWORKS path
[Number1] := 0
[Number1] := PositionOf ":\" in [PATHWORKS_path]
If [Number1] <> 0
DecrementNumber [Number1]
[PATHWORKS_drive] := SubstringOf [PATHWORKS_path] from Beginning to [Number1]
EndIf
;; Check if PATHWORKS drive is remote
If DriveIsRemote [PATHWORKS_drive]
Goto ExitCheckforPWSetup
EndIf ;; End If DriveIsRemote
;; remove the "PWTCP.INI" from the path
[Number1] := 0
[Number1] := PositionOf "PWTCP.INI" in [PATHWORKS_path]
If [Number1] <> 0
DecrementNumber [Number1]
[PATHWORKS_path2] := SubstringOf [PATHWORKS_path] from Beginning to [Number1]
EndIf
;; Enforce that the following files are ALL copied even if local copy is READ-ONLY
SetReadOnlyInquiry Off
;; Save copy of PATHWORKS file
CopyFiles from [PATHWORKS_path2] to [PATHWORKS_path2] quietly
PWTCP.INI as PWTCP.PW5
EndCopyFiles
;; Check if DECPW.386 in \WINDOWS directory; should ONLY be in \WINDOWS\SYSTEM
If FileExists [WindowsDirectory]\DECPW.386
;; Check if DECPW.386 in \WINDOWS\SYSTEM directory
If FileExists [WindowsDirectory]\SYSTEM\DECPW.386
;; Use COPY and DELETE because RENAME can cause error message if file exists
;; Save \WINDOWS version and use \WINDOWS\SYSTEM version
CopyFiles from [WindowsDirectory] to [WindowsDirectory] quietly
DECPW.386 as DECPW.BCK
EndCopyFiles
;; Delete \WINDOWS\DECPW.386; should ONLY be in \WINDOWS\SYSTEM
DeleteFiles from [WindowsDirectory]
DECPW.386
EndDeleteFiles
Else ;; Only \WINDOWS version exists
;; Save \WINDOWS version
CopyFiles from [WindowsDirectory] to [WindowsDirectory] quietly
DECPW.386 as DECPW.BCK
EndCopyFiles
;; Copy \WINDOWS version to \WINDOWS\SYSTEM and use
CopyFiles from [WindowsDirectory] to [WindowsDirectory]\SYSTEM quietly
DECPW.BCK as DECPW.386
EndCopyFiles
;; Delete \WINDOWS\DECPW.386; should ONLY be in \WINDOWS\SYSTEM
DeleteFiles from [WindowsDirectory]
DECPW.386
EndDeleteFiles
EndIf ;; End If \WINDOWS\SYSTEM\DECPW.386 exists
EndIf ;; End If \WINDOWS\DECPW.386 exists
;; Turn back on READ-ONLY file attribute inquiry for copying
SetReadOnlyInquiry On
;; Modify PATHWORKS V5.1 PWTCP.INI settings to HUBwatch defaults
ModifyTextFile [PATHWORKS_path]
InSection [TCPIP]
AddOrChangeLineWith (UDPMaxSock,=,) as "UDPMaxSock = 10" At End
EndModifyTextFile ;; close TCPIP.INI file
:ExitCheckforPWSetup
EndProcedure ;; Procedure CheckforPWSetup
;;----------------------------------------------------------------------
;; handle adding a program group
;;----------------------------------------------------------------------
Procedure AddToProgramManager
;; Prompt for the target drive and directory if they are unknown.
Do GetProductPath
If [InstallationDirectory] = BlankString
[StopInstall] := YesCharacter
Goto ExitAddToProc
EndIf
;; SLL -- HUBload
Do GetSubProductPath
[Product_Executable] := [InstallationDirectory]\[ExecutableName]
;; SLL -- HUBload
[SubProduct_Executable] := [SubProductInstallDir]\[SubExecutableName]
[GroupTitle] := [ProductName] for Windows
TextBox @xy(Center,50)
Use the [Up Arrow] and [Down Arrow] keys to move the highlight bar
to the desired operation. Press [Enter] or click on 'OK' to make
your selection. Press [Esc] to stop the installation.
EndTextBox
GetMenuChoice DisallowIfNone Highlight 1 UseHeader "Install Icon"
Install icons in [ProductName] Windows Group
;To create icons and put them in their own window group.
Install icons in an existing group
;To create icons and add them to an existing window group.
Do not install icons
;To skip creating icons. [ProductName], [SubProductName], and [NETRSubProductName]
;can be run from the Run... menu selection under the File menu in
;the Windows Program Manager or File Manager.
EndGetMenuChoice
ClearScreen
InCase choice is
=1:
TextBox @xy(center, center) YellowOnBlue
Adding INSTALIT Icon(s) To Windows Group
[GroupTitle]
EndTextBox
Do AddIcons
ClearScreen
=2:
[Array2] := GetProgramManagerGroupNames
[String1] := [Array2][1]
DialogBox 177 80 UseHeader "Choose group to install Icon in" BlackOnLightGray Returns [Number7]
ListBox @xy(15,7) 120 50 Uses [String1] LoadWith [Array2] Border
PushButton @xy(30,60) 38 14 "OK" OK
PushButton @xy(110,60) 38 14 "CANCEL" 100
EndDialogBox
If (Escaped) .OR. ([Number7] = 100)
[String1] = BlankString
EndIf
if [String1] = BlankString
PopUp NOTE: No Group Selected, Not Installing Icon(s).
else
[GroupTitle] := [String1]
TextBox @xy(center, center) YellowOnBlue
Adding INSTALIT Icon(s) To Windows Group
[GroupTitle]
EndTextBox
Do AddIcons
ClearScreen
endif
=3:
PopUp NOTE: No Icons Will Be Installed.
EndInCase
:ExitAddToProc
EndProcedure ;; Procedure AddToProgramManager
;;----------------------------------------------------------------------
;; This procedure gets the installation directory for the product files
;;----------------------------------------------------------------------
Procedure GetProductPath
If [ProductInstallDir] <> BlankString
[InstallationDirectory] := [ProductInstallDir]
Goto ExitGetProdPath
EndIf
:GetProdPathLabel
[String2] := [BootDrive]:[DefaultProductDirectory]
TextBox @xy(Center,75)
Press [Esc] to terminate the installation.
EndTextBox
DialogBox 177 50 UseHeader "Specify path to [ProductName]" BlackOnLightGray Returns [Number7]
EditText @xy(15,7) 120 14 Uses [String2] AutoHScroll Border UpperCase
PushButton @xy(30,30) 38 14 "OK" OK
PushButton @xy(90,30) 38 14 "CANCEL" 100
EndDialogBox
If (Escaped) .OR. ([Number7] = 100)
[InstallationDirectory] := BlankString
Goto ExitGetProdPath
EndIf
If FileExists [String2]\[ProductRequiredFile]
[InstallationDirectory] := [String2]
[ProductInstallDir] := [String2]
else
Popup Invalid [String2]. Software files not found.
Goto GetProdPathLabel
EndIf
:ExitGetProdPath
EndProcedure ;; Procedure GetProductPath
;;----------------------------------------------------------------------
;; This procedure gets the installation directory for the subproduct files
;;----------------------------------------------------------------------
Procedure GetSubProductPath
If [SubProductInstallDir] <> BlankString
Goto ExitGetSubProdPath
EndIf
:GetSubProdPathLabel
[String2] := InstallationDrive:[DefaultSubProductDirectory]
DialogBox 177 50 UseHeader "Specify path to [SubProductName]" BlackOnLightGray Returns [Number7]
EditText @xy(15,7) 120 14 Uses [String2] AutoHScroll Border UpperCase
PushButton @xy(30,30) 38 14 "OK" OK
PushButton @xy(90,30) 38 14 "CANCEL" 100
EndDialogBox
If (Escaped) .OR. ([Number7] = 100)
Goto ExitGetSubProdPath
EndIf
If FileExists [String2]\[SubProductRequiredFile]
[SubProductInstallDir] := [String2]
else
Popup Invalid [String2]. Software files not found.
Goto GetSubProdPathLabel
EndIf
:ExitGetSubProdPath
EndProcedure ;; Procedure GetSubProductPath
;;----------------------------------------------------------------------
;; Set the path for the user-editable (data) files
;;----------------------------------------------------------------------
Procedure SetPathToPrefFiles
;; BEWC 5/11/95 Indicate EXM does not work
;;TextBox @xy(Center,75)
;; CREATE CONFIGURATION EXAMPLE FILES OPTION(2) DOES NOT WORK...
;;EndTextBox
;;BEWC 7/26/94 Add product section and path in WIN.INI
ModifyTextFile [WindowsDirectory]\win.ini
;; Add product section
AddOrChangeLineWith ([HUBwatchSection],,) as "[HUBwatchSection]" At End
;; Add product path statement
AddOrChangeLineWith ([HUBwatchPath],=,) as "[HUBwatchPath]=[InstallationDirectory]" At End
;; Add product section for HUBload
AddOrChangeLineWith ([HUBloadSection],,) as "[HUBloadSection]" At End
;; Add product path statement
AddOrChangeLineWith ([HUBloadPath],=,) as "[HUBloadPath]=[SubProductInstallDir]" At End
EndModifyTextFile ;; close win ini file
If [SubdirectoryPath] <> BlankString
;; BEWC 7/25/94 Add WSAVERS(WINSOCK.DLL Version) environment variable in AUTOEXEC.BAT
;; BEWC 9/26/94 Add Windows directory to End of Path statement ONLY if does not exist
;; BEWC 4/26/95 Rid of ModifyAutoexecBat Procedure problems with Visual Release installer V6.06
;; BEWC 5/11/95 change to bootdrive
ModifyTextFile [BootDrive]:\autoexec.bat
AddOrChangeLineWith (WSAVERS,,) as "set WSAVERS=1.1" At Beginning
AddOrChangeLineWith (HUBWATCH_LIBRARY,,) as "set HUBWATCH_LIBRARY=[SubdirectoryPath]" At Beginning
AddPathComponent [WindowsDirectory] At End
EndModifyTextFile ;; close AUTOEXEC.BAT file
[AutoFile] := "AUTOEXEC.BAT"
;; BEWC 2/17/95 change HUBWATCH_LOAD to HUBWATCH_HUBLOADER environment variable name
;; SLL 11/23/94 -- set HUBWATCH_HUBLOADER for HUBload
;; BEWC 4/26/95 Rid of ModifyAutoexecBat Procedure problems with Visual Release installer V6.06
If [DoBothEnvVariables] = YesCharacter
;; BEWC 5/11/95 change to bootdrive
ModifyTextFile [BootDrive]:\autoexec.bat
AddOrChangeLineWith (HUBWATCH_HUBLOADER,,) as "set HUBWATCH_HUBLOADER=[SubProductInstallDir]" At Beginning
EndModifyTextFile ;; close AUTOEXEC.BAT file
EndIf
;; BEWC 3/30/95 Remove HUBWATCH_SYSTEM environment variable
[HUBWATCH_SYSTEM_string] := BlankString
[EditAutoexec] := NoCharacter
ExamineTextFile [BootDrive]:\autoexec.bat
[String1] := LineWith (HUBWATCH_SYSTEM,=,)
If [String1] <> BlankString ;; If found line with HUBWATCH_SYSTEM
[Number1] := PositionOf "REM" in [String1]
If [Number1] = 0 ;; If did not find REM in HUBWATCH_SYSTEM line
[HUBWATCH_SYSTEM_string] := "REM [String1]" ;; Add REM to HUBWATCH_SYSTEM
[EditAutoexec] := YesCharacter
EndIf
EndIf
ForgetTextFile ;; Close autoexec.bat
;; BEWC 3/30/95 Remove HUBWATCH_SYSTEM environment variable
If [EditAutoexec] = YesCharacter
;; BEWC 4/26/95 Rid of ModifyAutoexecBat Procedure problems with Visual Release installer V6.06
;; BEWC 5/11/95 change to bootdrive
ModifyTextFile [BootDrive]:\autoexec.bat
AddOrChangeLineWith (HUBWATCH_SYSTEM,=,) as "[HUBWATCH_SYSTEM_string]" At End
EndModifyTextFile ;; close AUTOEXEC.BAT file
EndIf
;; reset modify mode
;; BEWC 5/11/95 SetModifyModeTo Undecided
EndIf ;; End If [SubdirectoryPath] <> BlankString
;;5/11/95 Clear TextBox error message
ClearScreen
EndProcedure ;; Procedure SetPathToPrefFiles
;;----------------------------------------------------------------------
;; Install Icons
;;----------------------------------------------------------------------
Procedure AddIcons
ProgramManagerDDe
CreateGroup([GroupTitle])
AddItem([Product_Executable],[ProductName])
AddItem([SubProduct_Executable],[SubProductName])
AddItem(InstallationDrive:[SubProductSub_Executable],[NetriderLoadIcon])
EndProgramManagerDDE
EndProcedure ;; Procedure AddIcons
;;BEWC 2/8/95 Add HUBwatch to be launched from Digital ManageWORKS
;;----------------------------------------------------------------------
;; set up for Digital ManageWORKS and PATHWORKS
;;----------------------------------------------------------------------
Procedure SetupForMWORKS
;; Verify user wants to integrate with ManageWORKS
DialogBox 230 106 UseHeader "Digital ManageWORKS Workgroup Administrator Integration" BlackOnLightGray Returns [Number7]
;; CText @xy(5,10) 200 8 "DO YOU WANT TO SETUP FOR DIGITAL MANAGEWORKS"
;; CText @xy(5,20) 200 8 "WORKGROUP ADMINISTRATOR ON A FIXED DRIVE?"
;; CText @xy(5,40) 200 8 "REQUIRES: ManageWORKS Workgroup Administrator V2.0 to"
;; CText @xy(5,50) 200 8 "be installed locally on a fixed disk. If not found on a local"
;; CText @xy(5,60) 200 8 "disk, a lengthy search may occur to locate ManageWORKS on all"
;; CText @xy(5,70) 200 8 "drives(including network drives if the network is loaded)."
DefPushButton @xy(122,90) 38 14 "NO" 100
PushButton @xy(40,90) 38 14 "YES" OK
EndDialogBox
;; If user selected to Exit
If (Escaped) .OR. ([Number7] = 100)
Goto ExitSetupForMWORKS
EndIf
;; ** Find ManageWORKS executable installation drive and directory. **
;; Note: From ManageWORKS Installation, MWORKS not in Path Statement
[MWORKS_path] := BlankString
[MW_files] := 0
[MW_flag] := 0
;; Check for ManageWORKS directory on devices
ClearScreen
;; BEWC 5/11/95 Move textbox to top of the display
TextBox @xy(Center,75)
Searching for [MWORKSProductName] on all devices...
EndTextBox
[MWORKS_path] := FullPathTo MWORKS.INI Search AllFixed
;; If no MAnageWORKS path found
If [MWORKS_path] = BlankString
;; Let user know cannot find ManageWORKS on any device, and exit this procedure
ClearScreen
Dialog PressAnyKey [PopupColors]
.c[ProductName] has NOT been integrated into [MWORKSProductName].
.cCould not locate installation of [MWORKSProductName] Version 2.0 on any device.
.cRefer to the READ_ME.TXT on diskette 1 for further information.
EndDialog
Goto ExitSetupForMWORKS
Else ;; Otherwise, found a ManageWORKS path searching all devices
;; Obtain drive letter from ManageWORKS path
[Number1] := 0
[Number1] := PositionOf ":\" in [MWORKS_path]
If [Number1] <> 0
DecrementNumber [Number1]
[MWORKS_drive] := SubstringOf [MWORKS_path] from Beginning to [Number1]
EndIf
;; Check if ManageWORKS drive is remote
If DriveIsRemote [MWORKS_drive]
;; Let user know cannot find ManageWORKS on local fixed device, and exit this procedure
ClearScreen
Dialog PressAnyKey [PopupColors]
.c[ProductName] has NOT been integrated into [MWORKSProductName].
.cLocation of the installation of [MWORKSProductName] is NOT on a local fixed disk.
.cRefer to the READ_ME.TXT on diskette 1 for further information.
EndDialog
Goto ExitSetupForMWORKS
EndIf ;; End If DriveIsRemote
EndIf
;; Text Box displayed till end of procedure for search delay; instead of blank screen.
ClearScreen
;; BEWC 5/11/95 Move textbox to top of the display
TextBox @xy(Center,75)
Integrating [MWORKSProductName]...
EndTextBox
;; remove the "MWORKS.INI" from the path
[Number1] := 0
[Number1] := PositionOf "MWORKS.INI" in [MWORKS_path]
If [Number1] <> 0
DecrementNumber [Number1]
[MWORKS_path] := SubstringOf [MWORKS_path] from Beginning to [Number1]
EndIf
;; If user types in incorrect ManageWORKS Path return here and reprompt
:get_path_mworks
;; Verify ManageWORKS Path with the user
DialogBox 220 96 UseHeader "Install Directory Verification" BlackOnLightGray Returns [Number7]
;; CText @xy(5,1) 200 8 "PLEASE VERIFY YOUR DIGITAL MANAGEWORKS"
;; CText @xy(5,11) 200 8 "WORKGROUP ADMINISTRATOR INSTALLATION DIRECTORY"
;; CText @xy(5,21) 200 8 "FOR DIGITAL MANAGEWORKS INTEGRATION"
;; CText @xy(5,31) 200 8 "ON A FIXED DRIVE."
;; CText @xy(5,41) 200 8 "Click on OK or Select another choice and press <Enter>."
;; CText @xy(5,51) 200 8 "syntax: device:\directory\subdirectory\"
EditText @xy(10,61) 200 12 Uses [MWORKS_path] AutoHScroll Border
PushButton @xy(40,80) 38 14 "OK" OK
PushButton @xy(122,80) 38 14 "CANCEL" 100
EndDialogBox
;; If user selected to Exit
If (Escaped) .OR. ([Number7] = 100)
Goto ExitSetupForMWORKS
Else ;; Otherwise, user selected OK or new MWORKS path
;; Check if MWORKS.INI file exists required to run ManageWORKS executable
If FileExists [MWORKS_path]MWORKS.INI
;; Check if SNMPOMM.INI exists required to invoke HUBwatch from ManageWORKS
If FileExists [MWORKS_path]DATABASE\SNMPOMM.INI
[MW_files] := 1
EndIf
EndIf
;; Check if ManageWORKS files are not found
If ([MW_files] <> 1)
;; If first time through display Verify Path message
If [MW_flag] = 0
ClearScreen
Dialog PressAnyKey [PopupColors]
.cPLEASE VERIFY [MWORKSProductName] PATH: [MWORKS_path]
EndDialog
[MW_flag] := [MW_flag] + 1
Goto get_path_mworks
Else ;; not first time through, display Not integrated message and exit
ClearScreen
Dialog PressAnyKey [PopupColors]
.c[ProductName] has NOT been integrated into [MWORKSProductName].
.c
.cThe following [MWORKSProductName] initialization files were NOT found:
.c[MWORKS_path]MWORKS.INI and [MWORKS_path]DATABASE\SNMPOMM.INI
.c
.cRefer to the READ_ME.TXT on diskette 1 for further information.
EndDialog
Goto ExitSetupForMWORKS
EndIf ;; End Else not first time
EndIf ;; End Else could not find user entered ManageWORKS path
EndIf ;; End Else user selected OK or new MWORKS path
;; If user types in incorrect HUBwatch Path return here and reprompt
:get_path_hubwatch
ClearScreen
;; Get HUBwatch product path
Do GetProductPath
If [InstallationDirectory] = BlankString
;; Let user know cannot find HUBwatch on any device, and exit this procedure
ClearScreen
Dialog PressAnyKey [PopupColors]
.c[ProductName] has NOT been integrated into [MWORKSProductName].
.cCould not locate installation of [HUBwatchProductName] Version 4.0 on any device.
EndDialog
Goto ExitSetupForMWORKS
EndIf
;; Get HUBwatch ManageWORKS sub directory
[HUBW_MWORKS_path] := [InstallationDirectory]\[MWORKSSubdirectoryName]
If FileExists [InstallationDirectory]\HUBWATCH.EXE
If FileExists [HUBW_MWORKS_path]\HUBWMWRK.EXE
Goto mworks_cont
Else ;; Error message, require HUBwatch v4.0 and exit
ClearScreen
Dialog PressAnyKey [PopupColors]
.c[ProductName] has NOT been integrated into [MWORKSProductName].
.c
.cCould NOT locate [HUBwatchProductName] Version 4.0 Installation.
.cRequired for [MWORKSProductName] integration.
EndDialog
Goto ExitSetupForMWORKS
EndIf
Else ;;Error message, could not find HUBwatch exe and try again
ClearScreen
Dialog PressAnyKey [PopupColors]
.cCould not locate [HUBwatchProductName] Executable, Please Verify Path.
EndDialog
[ProductInstallDir] := BlankString
Goto get_path_hubwatch
EndIf
;; ManageWORKS integration Continue
:mworks_cont
;; Add HUBwatch path to SNMPOMM.INI file in HUBwatch section
;; BEWC 4/20/95 Remove MWORKS default PUBLIC command line option for HUBwatch
ModifyTextFile [MWORKS_path]\DATABASE\SNMPOMM.INI
InSection [HUBWATCH]
AddOrChangeLineWith (binary,=,) as "binary=[HUBW_MWORKS_path]\hubwmwrk.exe" At End
;; AddOrChangeLineWith (command,=,) as "command=<InternetAddress>" At End
EndModifyTextFile ;; close SNMPOMM.INI file
ClearScreen
;; Verify user is not using another TCP/IP stack
DialogBox 220 56 UseHeader "Digital TCP/IP Stack Verification" BlackOnLightGray Returns [Number7]
;; CText @xy(5,10) 200 8 "ARE YOU USING PATHWORKS V5.1 TCP/IP STACK"
;; CText @xy(5,20) 200 8 "OR HUBWATCH FOR WINDOWS 4.0 IP STACK?"
PushButton @xy(40,40) 38 14 "YES" OK
PushButton @xy(122,40) 38 14 "NO" 100
EndDialogBox
;; If user selected to Esc or NO button
If (Escaped) .OR. ([Number7] = 100)
;; Let user know successful installation of ManageWORKS integration
ClearScreen
Dialog PressAnyKey [PopupColors]
.c[ProductName] has been integrated into [MWORKSProductName].
EndDialog
Goto ExitSetupForMWORKS
EndIf
;; ** Find PATHWORKS or HUBwatch TCP/IP executable installation drive and directory. **
[PATHWORKS_path] := BlankString
[PW_files] := 0
[PW_flag] := 0
[NoVerifyFlag] := 0
;; If installing HUBwatch with the Network
If [DoNetworkInstall] = YesCharacter
;; Use the HUBwatch installation path
[PATHWORKS_path] := [InstallationDirectory]\[NetworkSubdirectoryName]\
Else ;; Otherwise, locate PATHWORKS path
;; Check for PATHWORKS directory on devices
ClearScreen
;; BEWC 5/11/95 Move textbox to top of the display
TextBox @xy(Center,75)
Searching for [PATHWORKSProductName] in PATH statement...
EndTextBox
;; Check for PATHWORKS directory in Path Statement
[PATHWORKS_path] := FullPathTo TCPIP.EXE PathOnly
;; If not PATHWORKS path found
If [PATHWORKS_path] = BlankString
;; Check for PATHWORKS directory on devices
ClearScreen
;; BEWC 5/11/95 Move textbox to top of the display
TextBox @xy(Center,75)
Searching for [PATHWORKSProductName] on all devices...
EndTextBox
[PATHWORKS_path] := FullPathTo TCPIP.EXE Search AllFixed
;; If no PATHWORKS path found
If [PATHWORKS_path] = BlankString
;; Let user know cannot find PATHWORKS on any device, and exit this procedure
ClearScreen
Dialog PressAnyKey [PopupColors]
.c[ProductName] has NOT been integrated into [MWORKSProductName].
.cCould not locate installation of [PATHWORKSProductName] on any device.
EndDialog
Goto ExitSetupForMWORKS
Else ;; Otherwise, found PATHWORKS TCPIP.EXE in on device
;; Verify PW path with user
Do VerifyPWPath
;; If Exit from VerifyPWPath
If [NoVerifyFlag] = 1
Goto ExitSetupForMWORKS
EndIf
EndIf ;; End Else found PATHWORKS TCPIP.EXE in on device
Else ;; Found PATHWORKS TCPIP.EXE in Path Statement
;; Verify PW path with user
Do VerifyPWPath
;; If Exit from VerifyPWPath
If [NoVerifyFlag] = 1
Goto ExitSetupForMWORKS
EndIf
EndIf ;; End Else Found PATHWORKS TCPIP.EXE in Path Statement
EndIf ;; End Else locate PATHWORKS path
ClearScreen
;; BEWC 5/11/95 Move textbox to top of the display
TextBox @xy(Center,75)
Modifying [PATHWORKSProductName] files...
EndTextBox
;; Enforce that the following files are ALL copied even if local copy is READ-ONLY
SetReadOnlyInquiry Off
;; Save copy of PATHWORKS file
CopyFiles from [PATHWORKS_path] to [PATHWORKS_path] quietly
PWTCP.INI as PWTCP.BCK
EndCopyFiles
If FileExists [PATHWORKS_path]\PROTOCOL.INI
CopyFiles from [PATHWORKS_path] to [PATHWORKS_path] quietly
PROTOCOL.INI as PROTOCOL.BCK
EndCopyFiles
EndIf
;; Turn back on READ-ONLY file attribute inquiry for copying
SetReadOnlyInquiry On
;; Modify SOCKET variables in PWTCP.INI file in TCPIP section
ModifyTextFile [PATHWORKS_path]\PWTCP.INI
InSection [TCPIP]
AddOrChangeLineWith (TCPMaxSock,=,) as "TCPMaxSock = 32" At End
AddOrChangeLineWith (UDPMaxSock,=,) as "UDPMaxSock = 10" At End
AddOrChangeLineWith (UDPMaxInputBuf,=,) as "UDPMaxInputBuf = 10" At Beginning
EndModifyTextFile ;; close PWTCP.INI file
[WFW_flag] := 0
;; BEWC 5/2/95 If installing with HUBwatch IP stack
If [DoNetworkInstall] = YesCharacter
;; Edit HUBwatch IP stack Windows formatted PROTOCOL.INI
[Number7] = 31
Else ;; Otherwise, using PW stack, check if running WFW or Windows
;; *** BEWC 4/14/95 Check if user is running WFW or Windows ***
DialogBox 210 86 UseHeader "Windows 3.1 Vs. WFW 3.11/MS Network Verification" BlackOnLightGray Returns [Number7]
;; CText @xy(5,10) 200 8 "ARE YOU USING WINDOWS 3.1 OR"
;; CText @xy(5,20) 200 8 "WINDOWS FOR WORKGROUPS 3.11 WITH"
;; CText @xy(5,30) 200 8 "THE MS NETWORK SETUP?"
;; CText @xy(5,45) 200 8 "Note: If you are running WFW BUT did not setup with"
;; CText @xy(5,55) 200 8 "the MS Network, then select the WINDOWS option."
PushButton @xy(30,70) 40 14 "WINDOWS" 31
PushButton @xy(80,70) 60 14 "WFW/NETWORK" 311
PushButton @xy(150,70) 38 14 "CANCEL" 100
EndDialogBox
;; If user selected to Esc or CANCEL button
If (Escaped) .OR. ([Number7] = 100)
;; Let user know successful installation of ManageWORKS integration
ClearScreen
Dialog PressAnyKey [PopupColors]
.c[ProductName] has been integrated into [MWORKSProductName].
.c
.cThe PATHWORKS V5.1 TCP/IP Stack OR the HUBwatch for Windows
.c4.0 IP Stack HAS NOT been modified with the required ManageWORKS
.cWorkgroup Administrator modifications.
EndDialog
Goto ExitSetupForMWORKS
EndIf
EndIf ;; BEWC 5/2/95 End Else check WFW vs.Windows
[String1] := BlankString
;; Check if Windows 3.1 was selected
If [Number7] = 31
;; Verify that PROTOCOL.INI path is correct
If FileExists [PATHWORKS_path]\PROTOCOL.INI
;; Modify Windows formatted PROTOCOL.INI
ExamineTextFile [PATHWORKS_path]\PROTOCOL.INI
[String1] := LineWith ([DATALINK],,)
ForgetTextFile ;; Close PROTOCOL.INI
If [String1] <> BlankString ;; If found [DATALINK] section
;; Modify BUFFER variable in PROTOCOL.INI file in DATALINK section
ModifyTextFile [PATHWORKS_path]\PROTOCOL.INI
InSection [DATALINK]
AddOrChangeLineWith (LG_BUFFERS,=,) as "LG_BUFFERS = 26" At End
EndModifyTextFile ;; close PROTOCOL.INI file
Else ;; Otherwise, did not find [DATALINK] section
ClearScreen
Dialog PressAnyKey [PopupColors]
.c[ProductName] has been integrated into [MWORKSProductName].
.c
.cMissing [DATALINK] section in the [PATHWORKS_path]\PROTOCOL.INI.
.c
.cYou must modify your PROTOCOL.INI [DATALINK] section LG_BUFFERS=26
.cfor [MWORKSProductName] support.
EndDialog
EndIf ;; [String1] <> BlankString
Else ;; Otherwise, PROTOCOL.INI does not exists in PATHWORKS directory
ClearScreen
Dialog PressAnyKey [PopupColors]
.c[ProductName] has been integrated into [MWORKSProductName].
.c
.cMissing [PATHWORKS_path]\PROTOCOL.INI.
.c
.cYou must modify your PROTOCOL.INI [DATALINK] section LG_BUFFERS=26
.cfor [MWORKSProductName] support.
EndDialog
EndIf ;; EndIf FileExists [PATHWORKS_path]\PROTOCOL.INI
Else ;; Check if Windows for Workgroup(WFW) 3.11
If [Number7] = 311
;; Verify WFW \WINDOWS\PROTOCOL.INI file path with the user
[WFW_protocol_path] := [WindowsDirectory]
:get_WFW_protocol_path
;; BEWC 5/2/95 Modify text in DialogBox
DialogBox 220 80 UseHeader "WFW Formatted PROTOCOL.INI Verification" BlackOnLightGray Returns [Number7]
;; CText @xy(5,1) 200 8 "PLEASE VERIFY YOUR WINDOWS FOR WORKGROUP"
;; CText @xy(5,11) 200 8 "FORMATTED PROTOCOL.INI DIRECTORY LOCATION."
;; CText @xy(5,21) 200 8 "Click on OK or Select another choice and press <Enter>."
;; CText @xy(5,31) 200 8 "syntax: device:\directory\subdirectory"
EditText @xy(10,41) 200 12 Uses [WFW_protocol_path] AutoHScroll Border
PushButton @xy(40,56) 50 14 "OK" OK
PushButton @xy(122,56) 50 14 "CANCEL" 100
EndDialogBox
;; If user selected to Esc or CANCEL button
If (Escaped) .OR. ([Number7] = 100)
;; Let user know successful installation of ManageWORKS integration
ClearScreen
Dialog PressAnyKey [PopupColors]
.c[ProductName] has been integrated into [MWORKSProductName].
.c
.cThe PATHWORKS V5.1 TCP/IP Stack OR the HUBwatch for Windows
.c4.0 IP Stack HAS NOT been modified with the required ManageWORKS
.cWorkgroup Administrator modifications.
EndDialog
Goto ExitSetupForMWORKS
EndIf
;; Verify that PROTOCOL.INI path is correct
If FileExists [WFW_protocol_path]\PROTOCOL.INI
;; Modify WFW formatted PROTOCOL.INI
ExamineTextFile [WFW_protocol_path]\PROTOCOL.INI
[String1] := LineWith ([DATALINKE],,)
ForgetTextFile ;; Close PROTOCOL.INI
If [String1] <> BlankString ;; If found [DATALINKE] section
;; Backup WFW PROTOCOL.INI
CopyFiles from [WFW_protocol_path] to [WFW_protocol_path] quietly
PROTOCOL.INI as PROTOCOL.BCK
EndCopyFiles
;; Modify BUFFER variable in PROTOCOL.INI file in DATALINKE section
ModifyTextFile [WFW_protocol_path]\PROTOCOL.INI
InSection [DATALINKE]
AddOrChangeLineWith (LG_BUFFERS,=,) as "LG_BUFFERS = 26" At End
EndModifyTextFile ;; close PROTOCOL.INI file
Else ;; Otherwise, did not find [DATALINKE] section
ClearScreen
Dialog PressAnyKey [PopupColors]
.c[ProductName] has been integrated into [MWORKSProductName].
.c
.cMissing [DATALINKE] section in the [WFW_protocol_path]\PROTOCOL.INI.
.c
.cYou must modify your PROTOCOL.INI [DATALINKE] section LG_BUFFERS=26
.cfor [MWORKSProductName] support.
EndDialog
EndIf ;; EndIf [String1] <> BlankString
Else ;; PROTOCOL.INI not found in user entered path
ClearScreen
Dialog PressAnyKey [PopupColors]
.cCould not locate [WFW_protocol_path]\PROTOCOL.INI, Please Verify Path.
EndDialog
Goto get_WFW_protocol_path
EndIf ;; EndIf FileExists [WFW_protocol_path]\PROTOCOL.INI
EndIf ;; EndIf [Number7] = 311
EndIf ;; EndIf [Number7] = 31
;; BEWC 5/2/95 START: If installing with HUBwatch IP stack
If [DoNetworkInstall] = YesCharacter
If [WFW_flag] = 0
[WFW_protocol_path] := [WindowsDirectory]
;; BEWC 5/2/95
DialogBox 220 141 UseHeader "WFW Formatted PROTOCOL.INI Verification" BlackOnLightGray Returns [Number7]
;; CText @xy(5,1) 200 8 "ARE YOU RUNNING WINDOWS FOR WORKGROUPS 3.11"
;; CText @xy(5,11) 200 8 "AND HAVE YOU CONFIGURED YOUR NETWORK WITH"
;; CText @xy(5,21) 200 8 "THE WFW NETWORK SETUP?"
;; CText @xy(5,36) 200 8 "If YES to both, select the WFW formatted"
;; CText @xy(5,46) 200 8 "PROTOCOL.INI location AND click on YES."
;; CText @xy(5,61) 200 8 "If you are not running WFW OR have not "
;; CText @xy(5,71) 200 8 "configured with the WFW Network Setup,"
;; CText @xy(5,81) 200 8 "click on NO."
;; CText @xy(5,96) 200 8 "syntax: device:\directory\subdirectory"
EditText @xy(10,106) 200 12 Uses [WFW_protocol_path] AutoHScroll Border
PushButton @xy(40,121) 38 14 "YES" OK
PushButton @xy(122,121) 38 14 "NO" 100
EndDialogBox
;; If user selected to Esc button
If (Escaped)
;; Let user know successful installation of ManageWORKS integration
ClearScreen
Dialog PressAnyKey [PopupColors]
.c[ProductName] has been integrated into [MWORKSProductName].
.c
.cThe PATHWORKS V5.1 TCP/IP Stack OR the HUBwatch for Windows
.c4.0 IP Stack HAS NOT been modified with the required ManageWORKS
.cWorkgroup Administrator modifications.
EndDialog
Goto ExitSetupForMWORKS
EndIf ;; EndIf Esc
;; If user did not select NO, select YES
If [Number7] <> 100
[WFW_flag] := 1
Goto get_WFW_protocol_path
EndIf ;; user select YES
EndIf ;; End If WFW_flag = 0
EndIf ;; EndIf If install HUBwatch IP stack
;; BEWC 5/2/95 END: If installing with HUBwatch IP stack
;; Enforce that the following files are ALL copied even if local copy is READ-ONLY
SetReadOnlyInquiry Off
;; Save copy of PATHWORKS file
If FileExists [PATHWORKS_path]\DNR.EXE
CopyFiles from [PATHWORKS_path] to [PATHWORKS_path] quietly
DNR.EXE as DNR.BCK
EndCopyFiles
EndIf
;; Save copy of PATHWORKS file
If FileExists [PATHWORKS_path]\WINSOCK.DLL
CopyFiles from [PATHWORKS_path] to [PATHWORKS_path] quietly
WINSOCK.DLL as WINSOCK.BCK
EndCopyFiles
EndIf
;; Copy PATHWORKS files from kit
CopyFiles from [HUBW_MWORKS_path] to [PATHWORKS_path] quietly
DNR.MWK as DNR.EXE
WINSOCK.MWK as WINSOCK.DLL
EndCopyFiles
;; Save copy of PATHWORKS file; Check if in \WINDOWS directory should be in \WINDOWS\SYSTEM only
;; Use COPY and DELETE because RENAME can cause error message if file exists
If FileExists [WindowsDirectory]\DECPW.386
CopyFiles from [WindowsDirectory] to [WindowsDirectory]quietly
DECPW.386 as DECPW.BCK
EndCopyFiles
;; Delete \WINDOWS\DECPW.386; should ONLY be in \WINDOWS\SYSTEM
DeleteFiles from [WindowsDirectory]
DECPW.386
EndDeleteFiles
EndIf
;; Save copy of PATHWORKS file
If FileExists [WindowsDirectory]\SYSTEM\DECPW.386
CopyFiles from [WindowsDirectory]\SYSTEM to [WindowsDirectory]\SYSTEM quietly
DECPW.386 as DECPW.BCK
EndCopyFiles
EndIf
;; Copy PATHWORKS file from kit
CopyFiles from [HUBW_MWORKS_path] to [WindowsDirectory]\SYSTEM quietly
DECPW.MWK as DECPW.386
EndCopyFiles
;; Turn back on READ-ONLY file attribute inquiry for copying
SetReadOnlyInquiry On
;; Add DNR.EXE to STRTNDIS.BAT, for HUBwatch \IPSTACK only
If FileExists [PATHWORKS_path]\STRTNDIS.BAT
ModifyTextFile [PATHWORKS_path]\STRTNDIS.BAT
AddOrChangeLineWith (dnr,,) as "dnr" At End
EndModifyTextFile ;; close STRTNDIS.BAT file
Else ;; Otherwise, FULL PW 5.1 installation, inform user to check PW Template file
ClearScreen
Dialog PressAnyKey [PopupColors]
.cEnsure that your [PATHWORKSProductName] v5.1 or greater
.cTemplate file(CFGnnnn.TPL) loads DNR.EXE.
EndDialog
EndIf
;; Add DNR.EXE to STRTODI.BAT, for HUBwatch \IPSTACK only
If FileExists [PATHWORKS_path]\STRTODI.BAT
ModifyTextFile [PATHWORKS_path]\STRTODI.BAT
AddOrChangeLineWith (dnr,,) as "dnr" At End
EndModifyTextFile ;; close STRTODI.BAT file
EndIf
;; Add DNR.EXE to STRTSLIP.BAT, for HUBwatch \IPSTACK only
If FileExists [PATHWORKS_path]\STRTSLIP.BAT
ModifyTextFile [PATHWORKS_path]\STRTSLIP.BAT
AddOrChangeLineWith (dnr,,) as "dnr" At End
EndModifyTextFile ;; close STRTSLIP.BAT file
EndIf
;; Let user know successful installation of ManageWORKS integration
ClearScreen
Dialog PressAnyKey [PopupColors]
.c[ProductName] has been integrated into [MWORKSProductName].
.c
.cThe [PATHWORKS_path] [PATHWORKSProductName] TCP/IP Stack and
.c[MWORKS_path] [MWORKSProductName] files
.chave been successfully modified.
.c
.cYou must restart the network.
EndDialog
ClearScreen
:ExitSetupForMWORKS
ClearScreen
EndProcedure ;; Procedure SetupForMWORKS
;;----------------------------------------------------------------------
;; Verify PATHWORKS path with the user.
;;----------------------------------------------------------------------
Procedure VerifyPWPath
;; Obtain drive letter from PATHWORKS path
[Number1] := 0
[Number1] := PositionOf ":\" in [PATHWORKS_path]
If [Number1] <> 0
DecrementNumber [Number1]
[PATHWORKS_drive] := SubstringOf [PATHWORKS_path] from Beginning to [Number1]
EndIf
;; Check if PATHWORKS drive is remote
If DriveIsRemote [PATHWORKS_drive]
;; Let user know cannot find PATHWORKS on local fixed device, and exit this procedure
ClearScreen
Dialog PressAnyKey [PopupColors]
.c[ProductName] has NOT been integrated into [MWORKSProductName].
.c
.cLocation of the installation of [PATHWORKSProductName] is not on a local fixed disk.
.c
.cMake sure [PATHWORKSProductName] is in your PATH statement on a local fixed disk.
EndDialog
[NoVerifyFlag] := 1
Goto ExitVerifyPWPath
EndIf ;; End If DriveIsRemote
;; remove the "TCPIP.EXE" from the path
[Number1] := 0
[Number1] := PositionOf "TCPIP.EXE" in [PATHWORKS_path]
If [Number1] <> 0
DecrementNumber [Number1]
[PATHWORKS_path] := SubstringOf [PATHWORKS_path] from Beginning to [Number1]
EndIf
;; If user types in incorrect PATHWORKS Path (from full devices search) return here and reprompt
:get_pw_path
;; Verify with the user
DialogBox 220 86 UseHeader "Install Directory Verification" BlackOnLightGray Returns [Number7]
;; CText @xy(5,1) 200 8 "PLEASE VERIFY YOUR DIGITAL PATHWORKS INSTALLATION"
;; CText @xy(5,11) 200 8 "DIRECTORY FOR DIGITAL MANAGEWORKS WORKGROUP"
;; CText @xy(5,21) 200 8 "ADMINISTRATOR INTEGRATION ON A FIXED DRIVE."
;; CText @xy(5,31) 200 8 "Click on OK or Select another choice and press <Enter>."
;; CText @xy(5,41) 200 8 "syntax: device:\directory\subdirectory\"
EditText @xy(10,51) 200 12 Uses [PATHWORKS_path] AutoHScroll Border
PushButton @xy(40,70) 38 14 "OK" OK
PushButton @xy(122,70) 38 14 "CANCEL" 100
EndDialogBox
ClearScreen
;; If user selected to Exit
If (Escaped) .OR. ([Number7] = 100)
[NoVerifyFlag] := 1
Goto ExitVerifyPWPath
Else ;; Otherwise, user selected OK or modified PW path
;; Check if PWTCP.INI file exists required to run PW TCP/IP executable
If FileExists [PATHWORKS_path]PWTCP.INI
[PW_files] := 1
EndIf
;; Check if PATHWORKS files are not found
If ([PW_files] <> 1)
;; If first time through display Verify Path message
If [PW_flag] = 0
Dialog PressAnyKey [PopupColors]
.cPLEASE VERIFY [PATHWORKSProductName] PATH: [PATHWORKS_path]
EndDialog
[PW_flag] := [PW_flag] + 1
Goto get_pw_path
Else ;; not first time through, display Not integrated message and exit
Dialog PressAnyKey [PopupColors]
.c[ProductName] has NOT been integrated into [MWORKSProductName].
.c
.cThe following [PATHWORKSProductName] initialization file
.cwas NOT found: [PATHWORKS_path]PWTCP.INI.
.c
.cRefer to the READ_ME.TXT on diskette 1 for further information.
EndDialog
[NoVerifyFlag] := 1
Goto ExitVerifyPWPath
EndIf ;; End Else not first time
EndIf ;; End If PW files not found
EndIf ;; End Else user selected OK or modified PW path
:ExitVerifyPWPath
EndProcedure ;; Procedure VerifyPWPath
;;----------------------------------------------------------------------
;; set up for HP OpenView
;;----------------------------------------------------------------------
Procedure SetupForOV
;; get ov ini file from win.ini
Do GetProductPath
If [InstallationDirectory] = BlankString
Goto ExitSetupForOV
EndIf
[String2] := [InstallationDirectory]\[OVSubdirectoryName]
[OVIniFile] := BlankString
ExamineTextFile [WindowsDirectory]\win.ini
[OVIniFile] := LineWith (OViniString,=,)
ForgetTextFile ;; Close win.ini
If [OVIniFile] <> BlankString
;; remove the "OViniString="
[Number1] := 0
[Number1] := PositionOf "=" in [OVIniFile]
If [Number1] <> 0
IncrementNumber [Number1]
[OVIniFile] := SubstringOf [OVIniFile] from [Number1] to End
EndIf
EndIf
If [OVIniFile] = BlankString
Goto ExitSetupForOV
EndIf
If [OVIniFile] <> BlankString
;; add our app, under [OpenViewApps]
If FileExists [OVIniFile]
[OVDir] := [OVIniFile]
;; remember the file so we can tell the user that we editted it
:StripLoop
[Number1] := 0
[Number1] := PositionOf "\" in [OVIniFile]
If [Number1] <> 0
IncrementNumber [Number1]
[OVIniFile] := SubstringOf [OVIniFile] from [Number1] to End
Goto StripLoop
EndIf
;; get the OpenView directory
[Number1] := 0
[Number1] := PositionOf [OVIniFile] in [OVDir]
If [Number1] <> 0
DecrementNumber [Number1]
DecrementNumber [Number1]
[OVDir] := SubstringOf [OVDir] from Beginning to [Number1]
EndIf
;; BUG WORKAROUND
;; INSTALIT thinks ovwin.ini is win.ini....
;; first backup the file as .0x
[Number1] := 0
[Number1] := PositionOf "." in [OVIniFile]
If [Number1] <> 0
DecrementNumber [Number1]
[FileForBackup] := SubstringOf [OVIniFile] from Beginning to [Number1]
[PathForBackup] := [OVDir]
Do MyBackupNameFor
CopyFiles from [OVDir] to [OVDir] quietly
[OVIniFile] as [BackupFileName]
EndCopyFiles
EndIf
;; copy it to a temp file
CopyFiles from [OVDir] to [OVDir] quietly
[OVIniFile] as [ProductName].tmp
EndCopyFiles
;; edit it
ModifyTextFile [OVDir]\[ProductName].tmp
InSection [OpenViewApps]
AddOrChangeLineWith ([OVAppName],=,) as "[OVAppName]=[String2]\[OVAppName].exe" At End
EndModifyTextFile ;; close ov ini file
;; copy it back
CopyFiles from [OVDir] to [OVDir] quietly
[ProductName].tmp as [OVIniFile]
EndCopyFiles
;; delete temp file
DeleteFiles from [OVDir] Quietly
[ProductName].tmp
EndDeleteFiles
;;change the device type numbers in the ov devices file
If FileExists [OVDir]\ovfiles\devices
ModifyTextFile [OVDir]\ovfiles\devices
AddOrChangeLineWith (1.3.6.1.4.1.36.2.15.10.1.1,,) as ""DEChub 90" 1.3.6.1.4.1.36.2.15.10.1.1 0x6368 HUB 0" At End
AddOrChangeLineWith (1.3.6.1.4.1.36.2.15.6.3.1,,) as ""DECserver 90TL" 1.3.6.1.4.1.36.2.15.6.3.1 0x6369 SERVER 0" At End
AddOrChangeLineWith (1.3.6.1.4.1.36.2.15.5.1.3,,) as ""DECserver 90TL" 1.3.6.1.4.1.36.2.15.5.1.3 0x6369 SERVER 0" At End
AddOrChangeLineWith (1.3.6.1.4.1.36.2.15.6.7.1,,) as ""DECserver 900TM" 1.3.6.1.4.1.36.2.15.6.7.1 0x6369 SERVER 0" At End
AddOrChangeLineWith (1.3.6.1.4.1.36.2.15.6.4.1,,) as ""DECserver 90M" 1.3.6.1.4.1.36.2.15.6.4.1 0x6369 SERVER 0" At End
AddOrChangeLineWith (1.3.6.1.4.1.36.2.15.6.8,,) as ""DECserver 900GM" 1.3.6.1.4.1.36.2.15.6.8 0x6369 SERVER 0" At End
AddOrChangeLineWith (1.3.6.1.4.1.36.2.15.6.8.1,,) as ""DECserver 900GM" 1.3.6.1.4.1.36.2.15.6.8.1 0x6369 SERVER 0" At End
AddOrChangeLineWith (1.3.6.1.4.1.36.2.15.3.7.1,,) as ""DECbridge 900MX" 1.3.6.1.4.1.36.2.15.3.7.1 0x636a BRIDGE 0" At End
AddOrChangeLineWith (1.3.6.1.4.1.36.2.15.3.8.1,,) as ""DECbridge 900EE" 1.3.6.1.4.1.36.2.15.3.8.1 0x636a BRIDGE 0" At End
AddOrChangeLineWith (1.3.6.1.4.1.36.2.15.3.9.1,,) as ""RoamAbout" 1.3.6.1.4.1.36.2.15.3.9.1 0x636a BRIDGE 0" At End
AddOrChangeLineWith (1.3.6.1.4.1.36.2.15.5.4.1,,) as ""DECconcentrator 900MX" 1.3.6.1.4.1.36.2.15.5.4.1 0x636b DTC 0" At End
AddOrChangeLineWith (1.3.6.1.4.1.36.2.15.5.5.1,,) as ""DECconcentrator 900TH" 1.3.6.1.4.1.36.2.15.5.5.1 0x636b DTC 0" At End
AddOrChangeLineWith (1.3.6.1.4.1.36.2.15.9.7.1,,) as ""DECrepeater 900TM" 1.3.6.1.4.1.36.2.15.9.7.1 0x636c REPEATER 0" At End
AddOrChangeLineWith (1.3.6.1.4.1.36.2.15.9.8.1,,) as ""DECrepeater 90TS" 1.3.6.1.4.1.36.2.15.9.8.1 0x636c REPEATER 0" At End
AddOrChangeLineWith (1.3.6.1.4.1.36.2.15.9.11.1,,) as ""DECrepeater 90FS" 1.3.6.1.4.1.36.2.15.9.11.1 0x636c REPEATER 0" At End
AddOrChangeLineWith (1.3.6.1.4.1.36.2.15.9.12.1,,) as ""DECrepeater 900FP" 1.3.6.1.4.1.36.2.15.9.12.1 0x636c REPEATER 0" At End
AddOrChangeLineWith (1.3.6.1.4.1.36.2.15.9.13.1,,) as ""DECrepeater 900GM" 1.3.6.1.4.1.36.2.15.9.13.1 0x636c REPEATER 0" At End
AddOrChangeLineWith (1.3.6.1.4.1.36.2.15.11.1,,) as ""DECbrouter 90T1" 1.3.6.1.4.1.36.2.15.11.1 0x636d ROUTER 0" At End
AddOrChangeLineWith (1.3.6.1.4.1.36.2.15.11.2,,) as ""DECbrouter 90T2" 1.3.6.1.4.1.36.2.15.11.2 0x636d ROUTER 0" At End
AddOrChangeLineWith (1.3.6.1.4.1.36.2.15.11.3,,) as ""DECbrouter 90T2A" 1.3.6.1.4.1.36.2.15.11.3 0x636d ROUTER 0" At End
AddOrChangeLineWith (DECbrouter,1.3.6.1.4.1.9.1.3,) as ""DECbrouter" 1.3.6.1.4.1.9.1.3 0x636d ROUTER 0" At End
AddOrChangeLineWith (1.3.6.1.4.1.36.2.15.4.5,,) as ""DECwanrouter 90" 1.3.6.1.4.1.36.2.15.4.5 0x732a ROUTER 0" At End
AddOrChangeLineWith (1.3.6.1.4.1.36.2.15.11.4.1,,) as ""RoutAbout Access 1" 1.3.6.1.4.1.36.2.15.11.4.1 0x732a ROUTER 0" At End
AddOrChangeLineWith (1.3.6.1.4.1.36.2.15.10.3.1,,) as ""DEChub 900" 1.3.6.1.4.1.36.2.15.10.3.1 0x732b HUB 0" At End
AddOrChangeLineWith (1.3.6.1.4.1.36.2.15.3.3,,) as ""DECgigaswitch" 1.3.6.1.4.1.36.2.15.3.3 0x732c HUB 0" At End
AddOrChangeLineWith (1.3.6.1.4.1.36.2.15.14.2.1,,) as ""DECgigaswitch/ATM" 1.3.6.1.4.1.36.2.15.14.2.1 0x732d HUB 0" At End
AddOrChangeLineWith (1.3.6.1.4.1.36.2.15.3.10.1,,) as ""PEswitch 900TX" 1.3.6.1.4.1.36.2.15.3.10.1 0x732e BRIDGE 0" At End
AddOrChangeLineWith (1.3.6.1.4.1.36.2.15.3.11.1,,) as ""DECswitch 900EF" 1.3.6.1.4.1.36.2.15.3.11.1 0x732e BRIDGE 0" At End
AddOrChangeLineWith (1.3.6.1.4.1.36.2.15.9.14.1,,) as ""PORTswitch 900TP" 1.3.6.1.4.1.36.2.15.9.14.1 0x732f REPEATER 0" At End
AddOrChangeLineWith (1.3.6.1.4.1.36.2.15.9.16.1,,) as ""PORTswitch 900CP" 1.3.6.1.4.1.36.2.15.9.16.1 0x732f REPEATER 0" At End
AddOrChangeLineWith (1.3.6.1.4.1.36.2.15.9.21.1,,) as ""PORTswitch 900FP" 1.3.6.1.4.1.36.2.15.9.21.1 0x732f REPEATER 0" At End
AddOrChangeLineWith (1.3.6.1.4.1.36.2.15.5.2,,) as ""DECmau 900TL" 1.3.6.1.4.1.36.2.15.5.2 0x7330 X25 0" At End
AddOrChangeLineWith (1.3.6.1.4.1.36.2.15.5.3.1,,) as ""DECmau 900TH" 1.3.6.1.4.1.36.2.15.5.3.1 0x7330 X25 0" At End
AddOrChangeLineWith (1.3.6.1.4.1.36.2.15.9.5,,) as ""DECrepeater 900TL" 1.3.6.1.4.1.36.2.15.9.5 0x7331 REPEATER 0" At End
AddOrChangeLineWith (1.3.6.1.4.1.36.2.15.9.9,,) as ""DECrepeater 900SL" 1.3.6.1.4.1.36.2.15.9.9 0x7331 REPEATER 0" At End
AddOrChangeLineWith (1.3.6.1.4.1.36.2.15.9.6,,) as ""DECrepeater 900FL" 1.3.6.1.4.1.36.2.15.9.6 0x7331 REPEATER 0" At End
AddOrChangeLineWith (1.3.6.1.4.1.36.2.15.10.1,,) as ""DECpacketprobe 90" 1.3.6.1.4.1.36.2.15.10.1 0x7332 ANALYZER 0" At End
AddOrChangeLineWith (1.3.6.1.4.1.141.1.1.3210.2,,) as ""DECpacketprobe 90" 1.3.6.1.4.1.141.1.1.3210.2 0x7332 ANALYZER 0" At End
AddOrChangeLineWith (1.3.6.1.4.1.141.1.1.3220.2,,) as ""DECpacketprobe 900RR" 1.3.6.1.4.1.141.1.1.3220.2 0x7333 ANALYZER 0" At End
EndModifyTextFile ;; close ov devices file
EndIf
;;finished editting the devices file
EndIf
EndIf
;; set paths in our ini file
ModifyTextFile [String2]\[OVAppName].ini
InSection [[OVAppName]]
AddOrChangeLineWith (SymbolsDir=,,) as "SymbolsDir=[String2]" At End
AddOrChangeLineWith ([ProductName]=,,) as "[ProductName]=[InstallationDirectory]\[ProductName].exe" At End
AddOrChangeLineWith (Version,=,) as "Version=[ProductVersion] [OVAppVersion]" At End
EndModifyTextFile ;; close our ini file
:ExitSetupForOV
EndProcedure ;; Procedure SetupForOV
;;----------------------------------------------------------------------
;; set up for Novell NMS
;;----------------------------------------------------------------------
Procedure SetupForNMS
;; get nms ini file
[NMSOlfPath] := BlankString
[NMSDllPath] := BlankString
[NMSIconPath] := BlankString
[NMSHelpPath] := BlankString
If FileExists [WindowsDirectory]\nms.ini
ExamineTextFile [WindowsDirectory]\nms.ini
[NMSOlfPath] := LineWith (OlfPath,=,)
[NMSDllPath] := LineWith (DllPath,=,)
[NMSIconPath] := LineWith (IconPath,=,)
[NMSHelpPath] := LineWith (HelpPath,=,)
ForgetTextFile ;; Close nms.ini
If [NMSOlfPath] <> BlankString
;; remove the "OlfPath="
[Number1] := 0
[Number1] := PositionOf "=" in [NMSOlfPath]
If [Number1] <> 0
IncrementNumber [Number1]
[NMSOlfPath] := SubstringOf [NMSOlfPath] from [Number1] to End
else
Goto ExitSetupForNMS
EndIf
EndIf
If [NMSDllPath] <> BlankString
;; remove the "DllPath="
[Number1] := 0
[Number1] := PositionOf "=" in [NMSDllPath]
If [Number1] <> 0
IncrementNumber [Number1]
[NMSDllPath] := SubstringOf [NMSDllPath] from [Number1] to End
else
Goto ExitSetupForNMS
EndIf
EndIf
If [NMSIconPath] <> BlankString
;; remove the "IconPath="
[Number1] := 0
[Number1] := PositionOf "=" in [NMSIconPath]
If [Number1] <> 0
IncrementNumber [Number1]
[NMSIconPath] := SubstringOf [NMSIconPath] from [Number1] to End
else
Goto ExitSetupForNMS
EndIf
EndIf
If [NMSHelpPath] <> BlankString
;; remove the "HelpPath="
[Number1] := 0
[Number1] := PositionOf "=" in [NMSHelpPath]
If [Number1] <> 0
IncrementNumber [Number1]
[NMSHelpPath] := SubstringOf [NMSHelpPath] from [Number1] to End
else
Goto ExitSetupForNMS
EndIf
EndIf
else
Goto ExitSetupForNMS
EndIf
If [NMSOlfPath] = BlankString
Goto ExitSetupForNMS
EndIf
If [NMSDllPath] = BlankString
Goto ExitSetupForNMS
EndIf
If [NMSIconPath] = BlankString
Goto ExitSetupForNMS
EndIf
If [NMSHelpPath] = BlankString
Goto ExitSetupForNMS
EndIf
Do GetProductPath
If [InstallationDirectory] = BlankString
Goto ExitSetupForNMS
EndIf
[String2] := [InstallationDirectory]\[NMSSubdirectoryName]
;;check for NMSOlfPath etc to exist
[copy_nms_files] := NoCharacter
If DirectoryExists [NMSOlfPath]
If DirectoryExists [NMSDllPath]
If DirectoryExists [NMSIconPath]
If DirectoryExists [NMSHelpPath]
[copy_nms_files] := YesCharacter
EndIf
EndIf
EndIf
EndIf
If [copy_nms_files] = NoCharacter
Goto ExitSetupForNMS
EndIf
CopyFiles from [String2] to [NMSOlfPath] quietly
*.olf
EndCopyFiles
CopyFiles from [String2] to [NMSDllPath] quietly
*.exe
EndCopyFiles
CopyFiles from [String2] to [NMSIconPath] quietly
*.ico
EndCopyFiles
;; CopyFiles from [String2] to [NMSHelpPath] quietly
;; *.hlp
;; EndCopyFiles
Run [NMSDllPath]\n-olfi.exe -f [NMSOlfPath]\dechwnms.olf
:ExitSetupForNMS
EndProcedure ;; Procedure SetupForNMS
;;----------------------------------------------------------------------
;; Handle the installation of the network
;;----------------------------------------------------------------------
Procedure InstallNetwork
QueFileGroup 5 to [InstallationDirectory]\[NetworkSubdirectoryName]
QueFileGroup 6 to [WindowsDirectory]\system
;; Prompt for the target drive and directory if they are unknown.
Do GetProductPath
If [InstallationDirectory] = BlankString
UnQueAllFiles
Goto ExitInstallNetwork
EndIf
CreateDirectoryIfNecessary [InstallationDirectory]\[NetworkSubdirectoryName]
;; Transfer the files to the target directory.
;; BEWC 5/11/95 Move textbox to top of the display
TextBox @xy(Center,75)
Copying files from disk...
EndTextBox
GetQuedFiles
ClearScreen
Dialog PressAnyKey [PopupColors]
.cNetwork files have been successfully copied to the
.c[InstallationDirectory] directory.
EndDialog
Do Config ;; configure the network
:ExitInstallNetwork
EndProcedure ;; Procedure InstallNetwork
;;----------------------------------------------------------------------
;; Handle the configuration of network parameters
;;----------------------------------------------------------------------
Procedure Config
;; Prompt for the target drive and directory if they are unknown.
:ConfigGetPath
Do GetProductPath
If [InstallationDirectory] = BlankString
Goto ExitConfigProc
EndIf
;; make sure the files we need for configuration are present
[PWInstallDir] := [InstallationDirectory]\[NetworkSubdirectoryName]
[Number1] := PositionOf ":" in [PWInstallDir]
[PWInstallDrive] := SubstringOf [PWInstallDir] from Beginning to [Number1]
IncrementNumber [Number1]
[PWInstallNoDrive] := SubstringOf [PWInstallDir] from [Number1] to End
[NetworkFilesFound] := NoCharacter
If FileExists [PWInstallDir]\pwtcp.ini
If FileExists [PWInstallDir]\strtndis.bat
If FileExists [PWInstallDir]\strtslip.bat
If FileExists [PWInstallDir]\stopnet.bat
If FileExists [PWInstallDir]\ewrk3.pro
If FileExists [PWInstallDir]\depca.pro
;; BEWC 8/16/94 add Other MAC drivers support
If FileExists [PWInstallDir]\smcmac.pro
If FileExists [PWInstallDir]\elnkii.pro
If FileExists [PWInstallDir]\elnkpl.pro
If FileExists [PWInstallDir]\elnk3.pro
If FileExists [PWInstallDir]\i82593.pro
If FileExists [PWInstallDir]\exp16.pro
If FileExists [PWInstallDir]\defea.pro
;; BEWC 2/21/95 add DEFEA driver NDIS support only
;; REMOVED If FileExists [PWInstallDir]\strtodi.bat
;; REMOVED If FileExists [PWInstallDir]\ewrk3.nc
;; REMOVED If FileExists [PWInstallDir]\depca.nc
[NetworkFilesFound] := YesCharacter
;; REMOVED EndIf
;; REMOVED EndIf
;; REMOVED EndIf
;; BEWC 8/16/94 add Other MAC drivers support
;; BEWC 2/21/95 add DEFEA driver NDIS support only
Endif ;;DEFEA
Endif ;;Exp16
Endif ;;i82593
Endif ;;elnk3
Endif ;;elnkpl
Endif ;;elnkii
Endif ;;smcmac
EndIf ;;depca
EndIf ;;ewrk3
EndIf ;;stopnet
EndIf ;;strtslip
EndIf ;;strtndis
EndIf ;;pwtcp.ini
If [NetworkFilesFound] = NoCharacter
;; network not installed here
Dialog PressAnyKey [PopupColors]
.cNetwork files not found.
EndDialog
If Escaped
Goto ExitConfigProc
EndIf
[ProductInstallDir] := BlankString
Goto ConfigGetPath
EndIf
Do SetConfigParams ;; setup ip addresses etc. in pwtcp.ini
If [StopInstall] = YesCharacter
Goto ExitConfigProc
EndIf
Do SetupStartFile ;; setup strtndis.bat, strtodi.bat, strtslip.bat
If [StopInstall] = YesCharacter
Goto ExitConfigProc
EndIf
Do SetupSystemIni ;; setup system.ini
If [StopInstall] = YesCharacter
Goto ExitConfigProc
EndIf
Do SetupAutoexec ;; setup autoexec.bat
If [StopInstall] = YesCharacter
Goto ExitConfigProc
EndIf
Do SetupConfigSys ;; setup config.sys
If [StopInstall] = YesCharacter
Goto ExitConfigProc
EndIf
[Figged] := YesCharacter
ClearScreen
Dialog PressAnyKey [PopupColors]
.cThe following files have been modified, and the
.coriginal files renamed with a .0x extension:
.c[SystemFile]
.c[ConfigFile]
.c[AutoFile]
.c[OVIniFile]
.cPWTCP.INI
.cSTOPNET.BAT
.cSTRTSLIP.BAT
.c[StartFile]
.c[ProtoFileExt]
EndDialog
:ExitConfigProc
EndProcedure ;; Procedure Config
;;----------------------------------------------------------------------
;; setup pwtcp.ini
;;----------------------------------------------------------------------
Procedure SetConfigParams
;; BEWC 5/11/95 Move textbox to top of the display
TextBox @xy(Center,75)
Getting configuration parameters...
EndTextBox
ExamineTextFile [PWInstallDir]\pwtcp.ini
[String1] := LineWith (IPAddress,=,)
[Number1] := PositionOf "=" in [String1]
IncrementNumber [Number1]
[String1] := SubstringOf [String1] from [Number1] to End
Do GetNextField
[HostIP] := [String2]
[String1] := LineWith (SubnetMask,=,)
[Number1] := PositionOf "=" in [String1]
IncrementNumber [Number1]
[String1] := SubstringOf [String1] from [Number1] to End
Do GetNextField
[SubNet] := [String2]
[String1] := LineWith (DefaultGW0,=,)
[Number1] := PositionOf "=" in [String1]
IncrementNumber [Number1]
[String1] := SubstringOf [String1] from [Number1] to End
Do GetNextField
[GateIP] := [String2]
[String1] := LineWith (UserName,=,)
[Number1] := PositionOf "=" in [String1]
IncrementNumber [Number1]
[String1] := SubstringOf [String1] from [Number1] to End
Do GetNextField
[Usrnam] := [String2]
[String1] := LineWith (HostName,=,)
[Number1] := PositionOf "=" in [String1]
IncrementNumber [Number1]
[String1] := SubstringOf [String1] from [Number1] to End
Do GetNextField
[NamePC] := [String2]
[String1] := LineWith (NameServer0,=,)
[Number1] := PositionOf "=" in [String1]
IncrementNumber [Number1]
[String1] := SubstringOf [String1] from [Number1] to End
Do GetNextField
[DnsIP] := [String2]
[String1] := LineWith (Domain,=,)
[Number1] := PositionOf "=" in [String1]
IncrementNumber [Number1]
[String1] := SubstringOf [String1] from [Number1] to End
Do GetNextField
[Domain] := [String2]
ForgetTextFile ;; Close PWTCP.INI
ClearScreen
;;BEWC 7/25/94 modified width of strings from 15(60) to 25(100) chars
:get_params
DialogBox 200 126 UseHeader "Set network configuration parameters" BlackOnLightGray Returns [Number7]
;; CText @xy(5,1) 200 8 "Ensure the following parameters are set properly"
;; CText @xy(5,11) 200 8 "for your network environment."
;; CText @xy(5,21) 200 8 "Use the <Tab> and Shift+<Tab> keys to move around."
RText @xy(10,40) 95 8 "Name of PC:"
EditText @xy(110,40) 100 8 Uses [NamePC]
RText @xy(10,50) 95 8 "IP Address of PC:"
EditText @xy(110,50) 100 8 Uses [HostIP]
RText @xy(10,60) 95 8 "IP Address of Gateway:"
EditText @xy(110,60) 100 8 Uses [GateIP]
RText @xy(10,70) 95 8 "Name of Local Domain:"
EditText @xy(110,70) 100 8 Uses [Domain]
RText @xy(10,80) 95 8 "IP Address of Name Server:"
EditText @xy(110,80) 100 8 Uses [DnsIP]
RText @xy(10,90) 95 8 "Network Subnet Mask:"
EditText @xy(110,90) 100 8 Uses [SubNet]
RText @xy(10,100) 95 8 "Username:"
EditText @xy(110,100) 100 8 Uses [Usrnam]
PushButton @xy(40,110) 38 14 "OK" OK
PushButton @xy(122,110) 38 14 "CANCEL" 100
EndDialogBox
If (Escaped) .OR. ([Number7] = 100)
[StopInstall] := YesCharacter
Goto ExitSetConfigProc
EndIf
;; confirm that the user is really done. He/she may have accidentally
;; hit the return key....
Dialog [YesOrNo1] [SpecialPopupColors]
The network parameter settings are:
Name of PC: [NamePC]
IP Address of PC: [HostIP]
IP Address of Gateway: [GateIP]
Name of Local Domain: [Domain]
IP Address of Name Server: [DnsIP]
Network Subnet Mask: [SubNet]
Username: [Usrnam]
Are these correct?
EndDialog
If Escaped
[StopInstall] := YesCharacter
Goto ExitSetConfigProc
EndIf
If [YesOrNo1] = NoCharacter
Goto get_params
EndIf
;; BEWC 5/11/95 Move textbox to top of the display
TextBox @xy(Center,75)
Setting configuration parameters...
EndTextBox
If [HostIP] = BlankString
[HostIP] := xxx.xxx.xxx.xxx
EndIf
If [Domain] = BlankString
[Domain] := xxx.xxx.xxx
EndIf
If [DnsIP] = BlankString
[DnsIP] := xxx.xxx.xxx.xxx
EndIf
If [Usrnam] = BlankString
[Usrnam] := xxx
EndIf
;; set the appropriate fields in pwtcp.ini (backing up existing file)
ModifyTextFile [PWInstallDir]\pwtcp.ini Quietly
InSection [TCPGLOBAL]
AddOrChangeLineWith (HostName,=,) as "HostName = [NamePC]" At Beginning
AddOrChangeLineWith (NetFiles,=,) as "NetFiles = [PWInstallDir]" At End
AddOrChangeLineWith (UserName,=,) as "UserName = [Usrnam]" At Beginning
InSection [TCPIP]
AddOrChangeLineWith (IPAddress,=,) as "IPAddress = [HostIP] ; Host ip address" At Beginning
AddOrChangeLineWith (SubnetMask,=,) as "SubnetMask = [SubNet] ; subnetmask" At Beginning
AddOrChangeLineWith (DefaultGW0,=,) as "DefaultGW0 = [GateIP] ; first default gateway" At Beginning
InSection [DNR]
AddOrChangeLineWith (Domain,=,) as "Domain = [Domain] ; name of local domain (eg," At Beginning
AddOrChangeLineWith (NameServer0,=,) as "NameServer0 = [DnsIP] ; IP address of first name server to" At Beginning
EndModifyTextFile
:ExitSetConfigProc
EndProcedure ;;Procedure SetConfigParams
;;----------------------------------------------------------------------
;; make appropriate edits to system.ini
;;----------------------------------------------------------------------
Procedure SetupSystemIni
If FileExists [WindowsDirectory]\system.ini
[FullNetworkString] := BlankString
[VpktdrvrString] := BlankString
[EditSystemIni] := NoCharacter
ExamineTextFile [WindowsDirectory]\system.ini
[String1] := LineWith (network=,decpw,386)
If [String1] = BlankString
[NetworkString] := BlankString
[NetworkRemark] := BlankString
[String1] := LineWith (network=,,)
[Number1] := PositionOf "=" in [String1]
If [Number1] <> 0
IncrementNumber [Number1]
[Number2] := PositionOf ";" in [String1]
If [Number2] = 0
[NetworkString] := SubstringOf [String1] from [Number1] to End
else
[NetworkRemark] := SubstringOf [String1] from [Number2] to End
DecrementNumber [Number2]
[NetworkString] := SubstringOf [String1] from [Number1] to [Number2]
EndIf
EndIf
If [NetworkString] = BlankString
[FullNetworkString] := "network=decpw.386[NetworkRemark]"
else
[FullNetworkString] := "network=[NetworkString],decpw.386[NetworkRemark]"
EndIf
If [FullNetworkString] <> [String1]
[EditSystemIni] := YesCharacter
EndIf
else ;;[String1] <> BlankString
[FullNetworkString] := [String1]
EndIf
[String1] := LineWith (vpktdrvr,386,)
If [String1] <> BlankString
[Number1] := PositionOf ";" in [String1]
If [Number1] = 0
[VpktdrvrString] := ";[String1]"
else
[VpktdrvrString] := [String1]
EndIf
If [VpktdrvrString] <> [String1]
[EditSystemIni] := YesCharacter
EndIf
EndIf
ForgetTextFile ;; Close system.ini
If [EditSystemIni] = YesCharacter
ModifyTextFile [WindowsDirectory]\system.ini
;;BEWC 3/1/95 InSection [BOOT]
;;BEWC 8/17/94 Add new PCSA driver for PW 5.1
;;BEWC 9/16/94 Remove PCSA50.drv (used for services which HUBwatch does not provide)
;; AddOrChangeLineWith (network.drv,=,) as "network.drv=pcsa50.drv" At Beginning
InSection [386Enh]
AddOrChangeLineWith (network=,,) as "[FullNetworkString]" At Beginning
AddOrChangeLineWith (vpktdrvr,386,) as "[VpktdrvrString]" At Beginning
EndModifyTextFile ;; system.ini
[SystemFile] := "SYSTEM.INI"
EndIf
EndIf ;; End If FileExists [WindowsDirectory]\system.ini
EndProcedure ;;Procedure SetupSystemIni
;;----------------------------------------------------------------------
;; make appropriate edits to autoexec.bat
;;----------------------------------------------------------------------
Procedure SetupAutoexec
;; BEWC 8/16/94 add Other MAC drivers support
[ewrk3_string] := BlankString
[depca_string] := BlankString
;; BEWC 2/21/95 add DEFEA driver NDIS support only
[defea_string] := BlankString
[smcmac_string] := BlankString
[elnkii_string] := BlankString
[elnkpl_string] := BlankString
[elnk3_string] := BlankString
[i82593_string] := BlankString
[exp16_string] := BlankString
[EditAutoexec] := NoCharacter
If FileExists [BootDrive]:\autoexec.bat
ExamineTextFile [BootDrive]:\autoexec.bat
[String1] := LineWith (ewrk3,,)
If [String1] <> BlankString
[Number1] := PositionOf "REM" in [String1]
If [Number1] = 0
[ewrk3_string] := "REM [String1]"
[EditAutoexec] := YesCharacter
else
[ewrk3_string] := [String1]
EndIf
EndIf
[String1] := LineWith (depca,,)
If [String1] <> BlankString
[Number1] := PositionOf "REM" in [String1]
If [Number1] = 0
[depca_string] := "REM [String1]"
[EditAutoexec] := YesCharacter
else
[depca_string] := [String1]
EndIf
EndIf
;; BEWC 2/21/95 add DEFEA driver NDIS support only
[String1] := LineWith (defea,,)
If [String1] <> BlankString
[Number1] := PositionOf "REM" in [String1]
If [Number1] = 0
[defea_string] := "REM [String1]"
[EditAutoexec] := YesCharacter
else
[defea_string] := [String1]
EndIf
EndIf
;; BEWC 8/16/94 add Other MAC drivers support
[String1] := LineWith (smcmac,,)
If [String1] <> BlankString
[Number1] := PositionOf "REM" in [String1]
If [Number1] = 0
[smcmac_string] := "REM [String1]"
[EditAutoexec] := YesCharacter
else
[smcmac_string] := [String1]
EndIf
EndIf
[String1] := LineWith (elnkii,,)
If [String1] <> BlankString
[Number1] := PositionOf "REM" in [String1]
If [Number1] = 0
[elnkii_string] := "REM [String1]"
[EditAutoexec] := YesCharacter
else
[elnkii_string] := [String1]
EndIf
EndIf
[String1] := LineWith (elnkpl,,)
If [String1] <> BlankString
[Number1] := PositionOf "REM" in [String1]
If [Number1] = 0
[elnkpl_string] := "REM [String1]"
[EditAutoexec] := YesCharacter
else
[elnkpl_string] := [String1]
EndIf
EndIf
[String1] := LineWith (elnk3,,)
If [String1] <> BlankString
[Number1] := PositionOf "REM" in [String1]
If [Number1] = 0
[elnk3_string] := "REM [String1]"
[EditAutoexec] := YesCharacter
else
[elnk3_string] := [String1]
EndIf
EndIf
[String1] := LineWith (i82593,,)
If [String1] <> BlankString
[Number1] := PositionOf "REM" in [String1]
If [Number1] = 0
[i82593_string] := "REM [String1]"
[EditAutoexec] := YesCharacter
else
[i82593_string] := [String1]
EndIf
EndIf
[String1] := LineWith (exp16,,)
If [String1] <> BlankString
[Number1] := PositionOf "REM" in [String1]
If [Number1] = 0
[exp16_string] := "REM [String1]"
[EditAutoexec] := YesCharacter
else
[exp16_string] := [String1]
EndIf
EndIf
[String1] := LineWith (set,WSAVERS,1.1)
If [String1] = BlankString
[EditAutoexec] := YesCharacter
EndIf
ForgetTextFile ;; Close autoexec.bat
EndIf ;;AUTOEXEC.BAT file exists
If [EditAutoexec] = YesCharacter
;; set environment variable and comment out driver left over from
;; HUBwatch 1.x (if any)
;; BEWC 5/11/95 Rid of ModifyAutoexecBat Procedure problems with Visual Release installer V6.06
ModifyTextFile [BootDrive]:\autoexec.bat
AddOrChangeLineWith (WSAVERS,,) as "set WSAVERS=1.1" At Beginning
AddOrChangeLineWith (ewrk3,,) as "[ewrk3_string]" At End
AddOrChangeLineWith (depca,,) as "[depca_string]" At End
;; BEWC 2/21/95 add DEFEA driver NDIS support only
AddOrChangeLineWith (defea,,) as "[defea_string]" At End
;; BEWC 8/16/94 add Other MAC drivers support
AddOrChangeLineWith (smcmac,,) as "[smcmac_string]" At End
AddOrChangeLineWith (elnkii,,) as "[elnkii_string]" At End
AddOrChangeLineWith (elnkpl,,) as "[elnkpl_string]" At End
AddOrChangeLineWith (elnk3,,) as "[elnk3_string]" At End
AddOrChangeLineWith (i82593,,) as "[i82593_string]" At End
AddOrChangeLineWith (exp16,,) as "[exp16_string]" At End
EndModifyTextFile ;; BEWC 5/11/95 End ModifyTextFile
[AutoFile] := "AUTOEXEC.BAT"
EndIf
If [StartFile] <> BlankString
Dialog [YesOrNo1] [SpecialPopupColors]
.cIn order to run [ProductName], the network will have
.cto be started by calling
.c[PWInstallDir]\[StartFile]
.cDo you want this command added to your autoexec.bat?
EndDialog
If Escaped
[StopInstall] := YesCharacter
Goto ExitSetupAutoexec
EndIf
If [YesOrNo1] = YesCharacter
ExamineTextFile [BootDrive]:\autoexec.bat
[Number1] := LineNumberWith (win,,)
;; SLL 11/30/94 -- make sure we don't put it before a
;; path statement
[Number2] := LineNumberWith (path,=,)
If [Number2] >= [Number1]
;; no win command, put it at the end of the file
[Number1] := 0
EndIf
[Number2] := LineNumberWith (=,windows,)
If [Number2] = [Number1]
;; no win command, put it at the end of the file
[Number1] := 0
EndIf
[Number2] := LineNumberWith ([StartFile],,)
If [Number2] <> 0
;; just editting the strtndis etc line; do not worry about
;; the win command
[Number1] := 0
EndIf
ForgetTextFile ;; Close autoexec.bat
If [Number1] <> 0
;; BEWC 5/11/95 Rid of ModifyAutoexecBat Procedure problems with Visual Release installer V6.06
;; BEWC 5/11/95 Indicate EXM does not work
;; TextBox @xy(Center,75)
;; CREATE CONFIGURATION EXAMPLE FILES OPTION(2) DOES NOT WORK...
;; EndTextBox
ModifyTextFile [BootDrive]:\autoexec.bat
InsertAtLine [Number1] if exist [PWInstallDir]\[StartFile] call [PWInstallDir]\[StartFile]
EndModifyTextFile
else
;; call startup file, at end of file
;; BEWC 5/11/95 Rid of ModifyAutoexecBat Procedure problems with Visual Release installer V6.06
ModifyTextFile [BootDrive]:\autoexec.bat
AddOrChangeLineWith ([StartFile],,) as "if exist [PWInstallDir]\[StartFile] call [PWInstallDir]\[StartFile]" At End
EndModifyTextFile
EndIf
[AutoFile] := "AUTOEXEC.BAT"
EndIf ;;YesOrNo1 = YES character
;; reset [StartFile], so it will not be mentioned twice when we exit
If [StartFile] = "STRTSLIP.BAT"
[StartFile] := BlankString
EndIf
EndIf ;;Start File <> BlankString
;; BEWC 5/11/95 Clear TextBox error message
ClearScreen
:ExitSetupAutoexec
;; BEWC 5/11/95 Clear TextBox error message
ClearScreen
EndProcedure ;;Procedure SetupAutoexec
;;----------------------------------------------------------------------
;; make appropriate edits to config.sys
;;----------------------------------------------------------------------
Procedure SetupConfigSys
;;BEWC 8/17/94 Add Other MAC drivers
[String2] := BlankString
[String3] := BlankString
[String4] := BlankString
[String5] := BlankString
[String6] := BlankString
[String7] := BlankString
[String8] := BlankString
[String9] := BlankString
[String10] := BlankString
[String11] := BlankString
[String12] := BlankString
[String13] := BlankString
[EditConfig] := NoCharacter
If FileExists [BootDrive]:\config.sys
[String2] := BlankString
ExamineTextFile [BootDrive]:\config.sys
[String1] := LineWith (device,protman,)
If [String1] <> BlankString
[Number1] := PositionOf "REM" in [String1]
If [Number1] = 0
[String2] := "REM [String1]"
[EditConfig] := YesCharacter
else
[String2] := [String1]
EndIf
EndIf
[String1] := LineWith (device,ewrk3,dos)
If [String1] <> BlankString
[Number1] := PositionOf "REM" in [String1]
If [Number1] = 0
[String3] := "REM [String1]"
[EditConfig] := YesCharacter
else
;;BEWC 8/17/94 following line missing in Version 2.0
[String3] := [String1]
EndIf
EndIf
[String1] := LineWith (device,depca,dos)
If [String1] <> BlankString
[Number1] := PositionOf "REM" in [String1]
If [Number1] = 0
[String4] := "REM [String1]"
[EditConfig] := YesCharacter
else
[String4] := [String1]
EndIf
EndIf
;; BEWC 2/21/95 add DEFEA driver NDIS support only
[String1] := LineWith (device,defea,dos)
If [String1] <> BlankString
[Number1] := PositionOf "REM" in [String1]
If [Number1] = 0
[String5] := "REM [String1]"
[EditConfig] := YesCharacter
else
[String5] := [String1]
EndIf
EndIf
;; BEWC 8/16/94 add Other MAC drivers support
[String1] := LineWith (device,smcmac,dos)
If [String1] <> BlankString
[Number1] := PositionOf "REM" in [String1]
If [Number1] = 0
[String6] := "REM [String1]"
[EditConfig] := YesCharacter
else
[String6] := [String1]
EndIf
EndIf
[String1] := LineWith (device,elnkii,dos)
If [String1] <> BlankString
[Number1] := PositionOf "REM" in [String1]
If [Number1] = 0
[String7] := "REM [String1]"
[EditConfig] := YesCharacter
else
[String7] := [String1]
EndIf
EndIf
[String1] := LineWith (device,elnkpl,dos)
If [String1] <> BlankString
[Number1] := PositionOf "REM" in [String1]
If [Number1] = 0
[String8] := "REM [String1]"
[EditConfig] := YesCharacter
else
[String8] := [String1]
EndIf
EndIf
[String1] := LineWith (device,elnk3,dos)
If [String1] <> BlankString
[Number1] := PositionOf "REM" in [String1]
If [Number1] = 0
[String9] := "REM [String1]"
[EditConfig] := YesCharacter
else
[String9] := [String1]
EndIf
EndIf
[String1] := LineWith (device,i82593,dos)
If [String1] <> BlankString
[Number1] := PositionOf "REM" in [String1]
If [Number1] = 0
[String10] := "REM [String1]"
[EditConfig] := YesCharacter
else
[String10] := [String1]
EndIf
EndIf
[String1] := LineWith (device,exp16,dos)
If [String1] <> BlankString
[Number1] := PositionOf "REM" in [String1]
If [Number1] = 0
[String11] := "REM [String1]"
[EditConfig] := YesCharacter
else
[String11] := [String1]
EndIf
EndIf
[String1] := LineWith (device,dis_pkt,gup)
If [String1] <> BlankString
[Number1] := PositionOf "REM" in [String1]
If [Number1] = 0
[String12] := "REM [String1]"
[EditConfig] := YesCharacter
else
[String12] := [String1]
EndIf
EndIf
[String1] := LineWith (device,netdev,)
If [String1] <> BlankString
[Number1] := PositionOf "REM" in [String1]
If [Number1] = 0
[String13] := "REM [String1]"
[EditConfig] := YesCharacter
else
[String13] := [String1]
EndIf
EndIf
ForgetTextFile ;; Close config.sys
EndIf ;;FileExists CONFIG.SYS
If [EditConfig] = YesCharacter
ModifyConfigSys
AddOrChangeLineWith (device,protman,) as "[String2]" At End
AddOrChangeLineWith (device,ewrk3,dos) as "[String3]" At End
AddOrChangeLineWith (device,depca,dos) as "[String4]" At End
;; BEWC 2/21/95 add DEFEA driver NDIS support only
AddOrChangeLineWith (device,defea,dos) as "[String5]" At End
;; BEWC 8/16/94 add Other MAC drivers support
AddOrChangeLineWith (device,smcmac,dos) as "[String6]" At End
AddOrChangeLineWith (device,elnkii,dos) as "[String7]" At End
AddOrChangeLineWith (device,elnkpl,dos) as "[String8]" At End
AddOrChangeLineWith (device,elnk3,dos) as "[String9]" At End
AddOrChangeLineWith (device,i82593,dos) as "[String10]" At End
AddOrChangeLineWith (device,exp16,dos) as "[String11]" At End
AddOrChangeLineWith (device,dis_pkt,gup) as "[String12]" At End
AddOrChangeLineWith (device,netdev,) as "[String13]" At End
EndModifyConfigSys
[ConfigFile] := "CONFIG.SYS"
EndIf
EndProcedure ;;Procedure SetupConfigSys
;;----------------------------------------------------------------------
;; initialization
;;----------------------------------------------------------------------
Procedure SetupInstalit
SetBackgroundCharTo B0
SetBackgroundColor 0 0 64 191 64 0
SetDefaultBitmap Off
If FileExists [InstallFromDirectory]\logo.bmp
CopyFiles from [InstallFromDirectory] to ShadowDirectory quietly
logo.bmp
EndCopyFiles
LoadBitMap ShadowDirectory\logo.bmp @xy(10,5)
ShowBitMap 1
EndIf
ShowWindow Maximize
[MinimumOSVersion] := 3.1
SetShadows On
SetMainBorderTo None
SetPopupBorderTo Single
SetShadowAttrTo LightGrayOnBlack
SetScreenAttrTo [ScreenColors]
SetPopupAttrTo [PopupColors]
SetAttentionAttrTo [AttentionColors]
SetTopLineTo [TopLine]
[ProductInstallDrive] := [BootDrive]
EndProcedure ;;Procedure SetupInstalit
;;----------------------------------------------------------------------
;; This procedure prepares the system configuration information. The
;; information will be used when F3 key is pressed.
;;----------------------------------------------------------------------
Procedure PrepareSystemReport
[InsufficientSystem] := NoCharacter
If WindowsVersion < [MinimumOSVersion]
[OSVersionSummary] := WindowsVersion (need at least [MinimumOSVersion])
[InsufficientSystem] := YesCharacter
else
[OSVersionSummary] := WindowsVersion
EndIf
[SystemMemorySummary] := MainMemoryK
If 808X
If [Allow808X] = YesCharacter
[CPUTypeSummary] := 808x
else
[CPUTypeSummary] := 808x (not compatible with [ProductName])
[InsufficientSystem] := YesCharacter
EndIf
EndIf
If 80286
[CPUTypeSummary] := 80286
EndIf
If 80386
[CPUTypeSummary] := 80386
EndIf
If 80486
[CPUTypeSummary] := 80486
EndIf
If [CPUTypeSummary] = BlankString
[CPUTypeSummary] := 808x
EndIf
If MicroChannel
[CPUTypeSummary] := [CPUTypeSummary] (in MicroChannel Architecture)
else
[CPUTypeSummary] := [CPUTypeSummary] (ISA or EISA Architecture)
EndIf
If CGA
If [AllowCGA] = YesCharacter
[DisplayAdapterSummary] := CGA
else
[DisplayAdapterSummary] := CGA (not compatible with [ProductName])
[InsufficientSystem] := YesCharacter
EndIf
EndIf
If MDA
If [AllowMDA] = YesCharacter
[DisplayAdapterSummary] := MDA
else
[DisplayAdapterSummary] := MDA (not compatible with [ProductName])
[InsufficientSystem] := YesCharacter
EndIf
EndIf
If EGA
[DisplayAdapterSummary] := EGA
EndIf
If VGA
[DisplayAdapterSummary] := VGA
EndIf
If HGC
[DisplayAdapterSummary] := HGC
EndIf
If HGCPlus
[DisplayAdapterSummary] := HGC Plus
EndIf
If Network
[NetworkActive] := Network Active
else
[NetworkActive] := No Network Active
EndIf
If NovellLoaded
[NetworkActive] := Novell [NetworkActive]
EndIf
If MathCoprocessorPresent
[MathCoprocessorStatus] := Present
else
If [MathCoprocessorRecommended] = YesCharacter
[MathCoprocessorStatus] := Not Present But Recommended
If [CompatibilityNoticeGiven] = YesCharacter
else
Dialog ;; Notice if math coprocessor recommended
[ProductName] needs a math coprocessor
for best performance. Your system does not
contain one.
EndDialog
EndIf
else
[MathCoprocessorStatus] := Not Present
EndIf
EndIf
If [InsufficientSystem] = YesCharacter
[String8] := (Please note the listed incompatibilities)
EndIf
If [NetworkInstallation] contains DisallowNetwork
[String9] := " (You cannot install this version on a network drive)"
EndIf
[CompatibilityNoticeGiven] := YesCharacter
If ([InsufficientSystem] = YesCharacter) .OR. ([NetworkInstallation] contains DisallowNetwork)
Do ShowSystemSummary
[Finished] := YesCharacter
EndIf
EndProcedure ;; Procedure PrepareSystemReport
;;----------------------------------------------------------------------
;;----------------------------------------------------------------------
Procedure GetNextField
Do StripBlank
[String2] := BlankString
[Number1] := PositionOf " " in [String1]
If [Number1] = 0
[String2] := SubstringOf [String1] from 1 to End
else
DecrementNumber [Number1]
[String2] := SubstringOf [String1] from 1 to [Number1]
EndIf
[Number1] := PositionOf ";" in [String2]
If [Number1] = 1 ;; Ignore a trailing comment
[String2] := BlankString
Goto ExitField
EndIf
IncrementNumber [Number1]
[String1] := SubstringOf [String1] from [Number1] to End
:ExitField
EndProcedure ;; Procedure GetNextField
;;----------------------------------------------------------------------
Procedure StripBlank
:StripAgain
[Number5] := 0
[Number5] := PositionOf " " in [String1]
If [Number5] = 1
[String1] := SubstringOf [String1] from 2 to End
Goto StripAgain
EndIf
EndProcedure
;;----------------------------------------------------------------------
;; This procedure handles the F3 key.
;;----------------------------------------------------------------------
Procedure ShowSystemSummary
Dialog PressAnyKey [SpecialPopupColors]
HERE IS A SUMMARY OF YOUR SYSTEM
[String8] ;; notes whether any incompatibilities were found
Operating System Version: [OSVersionSummary]
CPU Type: [CPUTypeSummary]
Display Adapter: [DisplayAdapterSummary]
Math Coprocessor: [MathCoprocessorStatus]
Main Memory Present: [SystemMemorySummary]
Extended Memory Present: ExtendedMemoryPresent
Network: [NetworkActive]
[String9] ;; information about network suitability
EndDialog
EndProcedure
;;----------------------------------------------------------------------
Procedure GetDestinationDrive
:GetDest
DetermineInstallationDrive QueSize ShowDriveWithSpace RequireFixed BernoulliAsFixed AllowNetwork
;;BEWC 9/29/94 Add terminate installation text when out of disk space.
TextBox @xy(Center,50)
Press [Esc] to terminate the installation.
EndTextBox
;; Make sure there is enough space to install the files.
If FreeSpaceOnDrive InstallationDrive < QueSize
Popup Not enough space on the selected drive.
Goto GetDest
EndIf
ClearScreen
EndProcedure ;; Procedure GetDestinationDrive
;;----------------------------------------------------------------------
;; MyBackupNameFor
;; determine a backup file name, since BackupNameFor does not seem to work
;;----------------------------------------------------------------------
Procedure MyBackupNameFor
[Number1] := 1
:back_label
If [Number1] < 10
[String1] := "0[Number1]"
else
[String1] := "[Number1]"
EndIf
If FileExists [PathForBackup]\[FileForBackup].[String1]
IncrementNumber [Number1]
Goto back_label
EndIf
[BackupFileName] := [FileForBackup].[String1]
EndProcedure ;;MyBackupNameFor
EndScript
|