home *** CD-ROM | disk | FTP | other *** search
/ Microsoft Internet Business Development Kit / PRODUCT_CD.iso / sqlsvr / ppc / setup.inf < prev    next >
Encoding:
INI File  |  1995-12-25  |  448.0 KB  |  11,018 lines

  1. [Shell Commands]
  2.     set-title "SQL Server Setup"
  3.     set-subst LF = "\n"
  4.     set Exit_Code = $(!SETUP_ERROR_GENERAL)
  5.     
  6.     ifstr(i) $(!STF_OS) == "NT"
  7.         install LoadSetupLibrary
  8.     else
  9.         install LoadSetupWLibrary
  10.     endif
  11.     
  12.     StartWait
  13.     read-syms GeneralConstants
  14.     read-syms LanguageVar
  15.     detect    LanguageVar
  16.     
  17.     ifstr(i) $(Debug) == "ON"
  18.         LibraryProcedure Result, $(!DLLSQL), Debugger "15"
  19.     endif
  20.     
  21. checksrcdir =+
  22.     read-syms UiVars
  23.     detect    UiVars
  24.     
  25.     read-syms SetupInstFlags
  26.     detect SetupInstFlags
  27.     
  28.     EndWait
  29.     read-syms InternationalSetup
  30.     read-syms SetupInit$(!STF_LANGUAGE)
  31.     
  32.     ifstr(i) $(!STF_OS) == "NT"
  33.         read-syms WindowsNT$(!STF_LANGUAGE)
  34.     else
  35.         read-syms Windows95$(!STF_LANGUAGE)
  36.     endif
  37.     
  38.     ifstr(i) $(!SQLBooksInst) == "NO"
  39.         set !SQLBooksType = "3"
  40.     endif
  41.     
  42.     LibraryProcedure !ComputerName, $(!DLLSQL), GetMachineName
  43.     LibraryProcedure !SQLSetupModule, $(!DLLSQL), SQLDLLInit $(STF_HWND)
  44.     LibraryProcedure !SetupFileVersion, $(!DLLSQL), GetProductFileVersion $(!SQLSetupModule)
  45.     LibraryProcedure TestKey, $(!DLLSQL), RegOpen "\\"$(!ComputerName),$(!RegSQLServerServer)"\"$(!RegSQLSvrParam)
  46.     ifstr(i) $(!STF_OS) == "NT"
  47.         LibraryProcedure !WrkStaVersion, $(!DLLSQL), IsWorkStationVersion $(!SQLReleaseNumber)
  48.     else
  49.         set !WrkStaVersion = "TRUE"
  50.     endif
  51.     ifstr(i) $(TestKey) != "KEY_ERROR"
  52.         set !SQL95Keys = "TRUE"
  53.         LibraryProcedure Result, $(!DLLSQL), RegClose $(TestKey)
  54.     endif
  55.     set !OldDSQuery = ""
  56.     set !ClientModKey = ""
  57.     LibraryProcedure ClientKey, $(!DLLSQL), RegOpen "\\"$(!ComputerName),$(!RegSQLClient)"\"$(!RegSQLConnectTo)
  58.     ifstr(i) $(ClientKey) == "KEY_ERROR"
  59.         set OldClientKey = "TRUE"
  60.         LibraryProcedure ClientKey, $(!DLLSQL), RegOpen "\\"$(!ComputerName),$(!RegOldSQLClient)"\"$(!RegSQLConnectTo)
  61.     else
  62.         set OldClientKey = "FALSE"
  63.     endif
  64.     ifstr(i) $(ClientKey) != "KEY_ERROR"
  65.         LibraryProcedure !OldDSQuery, $(!DLLSQL), RegRead $(ClientKey),$(!RegValDSQUERY)
  66.         LibraryProcedure !OldMachineAlias, $(!DLLSQL), RegRead $(ClientKey),$(!ComputerName)
  67.         ifstr(i) $(!OldDSQuery) == "KEY_ERROR"
  68.             set !OldDSQuery = ""
  69.         else
  70.             LibraryProcedure Result, $(!DLLSQL), RegClose $(ClientKey)
  71.             set ClientKey = ""
  72.             set ModClient = "TRUE"
  73.         endif
  74.         ifstr(i) $(ClientKey) != ""
  75.             LibraryProcedure Result, $(!DLLSQL), RegClose $(ClientKey)
  76.         endif
  77.     endif
  78.     shell "" GetAliasConnectTo $(!ComputerName)
  79.     shell "" DoNetDefaults
  80.     
  81.     ifstr(i) $(!SQL95Keys) != "TRUE"
  82.         ifstr(i) $(ClientModKey) != ""
  83.             LibraryProcedure Result, $(!DLLSQL), RegClose $(ClientModKey)
  84.             set ClientModKey = ""
  85.         endif
  86.         ifstr(i) $(!STF_OS) == "NT"
  87.             shell "" DoDupKeys
  88.             ifstr(i) $($R0) == "STATUS_SUCCESSFUL"
  89.                 set !KeysDupped = "TRUE"
  90.             else
  91.                 set !KeysDupped = "FALSE"
  92.             endif
  93.         else
  94.             set KeysDupped = "FALSE"
  95.         endif
  96.         ifstr(i) $(ModClient) == "TRUE"
  97.             LibraryProcedure !ClientModKey, $(!DLLSQL), RegMakeKey "\\"$(!ComputerName),$(!RegSQLClient),$(!RegSQLConnectTo),""
  98.             LibraryProcedure Result, $(!DLLSQL), RegSet $(!ClientModKey),$(!RegValDSQUERY),$(!RegTypeString),$(!ClientLibPipes),""
  99.         endif
  100.         ifstr(i) $($R0) == "STATUS_FAILED"
  101.             goto setupnotdone
  102.         endif
  103.     else
  104.         ifstr(i) $(ModClient) == "TRUE"
  105.             LibraryProcedure !ClientModKey, $(!DLLSQL), RegMakeKey "\\"$(!ComputerName),$(!RegSQLClient),$(!RegSQLConnectTo),""
  106.             LibraryProcedure Result, $(!DLLSQL), RegSet $(!ClientModKey),$(!RegValDSQUERY),$(!RegTypeString),$(!ClientLibPipes),""
  107.         endif
  108.         LibraryProcedure OpenServerKey, $(!DLLSQL), RegOpen "\\"$(!ComputerName),$(!RegSQLServer)"\"$(!RegSQLServerSvr)
  109.         ifstr(i) $(OpenServerKey) != "KEY_ERROR"
  110.             LibraryProcedure !OldListenOn, $(!DLLSQL), RegRead $(!OpenServerKey),$(!RegValListenOn)
  111.             LibraryProcedure Result, $(!DLLSQL), RegClose $(OpenServerKey)
  112.         else
  113.             set !OldListenOn = {}
  114.             set !OldListenOn = >( $(!NetLibPipes),","$(!ServerNMPipeName))
  115.         endif
  116.     endif
  117.     read-syms FailedUserSetupQuit$(!STF_LANGUAGE)
  118. win95utils_back =+
  119.     shell "" DoWelcome
  120.     ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  121.         goto setupnotdone
  122.     endif
  123.     
  124.     shell "" DoTestSQLServer60
  125.     ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  126.         read-syms OldSQLBeta3$(!STF_LANGUAGE)
  127.         set !Addl95Text = " "
  128.         goto setupnotdone
  129.     endif
  130.     
  131.     shell "" DoCheckOS
  132.     ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  133.         goto setupnotdone
  134.     endif
  135.     
  136.     shell "" DoSetLocalSetup
  137.     ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  138.         goto setupnotdone
  139.     endif
  140.     set !AllowExit = "YES"
  141.     set !OldRemoteComputer = $(!RemoteComputer)
  142.     
  143.     ifstr(i) $(!STF_OS) == "NT"
  144.         shell "" DoCheckServerKeyAccess
  145.         ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  146.             goto setupnotdone
  147.         endif
  148.     endif
  149.     
  150.     ifstr(i) $(!RegistryRebuild) != ""
  151.         ifstr(i) $(!STF_OS) == "NT"
  152.             shell "" StopService $(!SQLMonitorService)
  153.             shell "" StopService $(!SQLSchedulerService)
  154.             shell "" StopService $(!SQLOldSchedulerService)
  155.             shell "" StopService $(!SQLOldServerService)
  156.             shell "" StopService $(!SQLServerService)
  157.             shell "" DoLicense
  158.             ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  159.                 goto setupnotdone
  160.             endif
  161.             shell "" DoNewInstall
  162.             ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  163.                 goto setupnotdone
  164.             else
  165.                 read-syms InstalledTag$(!STF_LANGUAGE)
  166.                 goto installdone
  167.             endif
  168.         endif
  169.     endif
  170. poseSetupType =+
  171.     ifstr(i) $(!STF_OS) == "95"
  172.         shell "" DoSelectClientInstall
  173.         ifstr(i) $($R0) == "STATUS_BACK"
  174.             goto win95utils_back
  175.         else-ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  176.             goto setupnotdone
  177.         endif
  178.         ifstr(i) $(!InstallType) == "3"
  179.             shell "" DoInstallUtils
  180.         else
  181.             shell "" DoClientNuke
  182.         endif
  183.         ifstr(i) $($R0) == "STATUS_BACK"
  184.             goto poseSetupType
  185.         else-ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  186.             goto setupnotdone
  187.         else
  188.             ifstr(i) $(!InstallType) == "3"
  189.                 read-syms UtilInstallTag$(!STF_LANGUAGE)
  190.             else
  191.                 read-syms CompletionClientNuked$(!STF_LANGUAGE)
  192.                 goto setupdone
  193.             endif
  194.             goto installdone
  195.         endif
  196.     endif
  197.     shell "" DoSetupType
  198.     ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  199.         goto setupnotdone
  200.     endif
  201.     ifstr(i) $(!InstallType) != "3"
  202.         shell "" DoAdminCheck
  203.         ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  204.             goto setupnotdone
  205.         endif
  206.     endif
  207.     ifstr(i) $(!InstallType) == "1"
  208.         shell "" DoTestSMS
  209.         ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  210.             read-syms SMSConflict$(!STF_LANGUAGE)
  211.             set !Addl95Text = " "
  212.             goto setupnotdone
  213.         endif
  214.         set !NewInstall = "TRUE"
  215.         shell "" DoClearInstallVars
  216.         ifstr(i) $(!KeysDupped) == "TRUE"
  217.             shell "" DoDelete95Key $(!ComputerName), ""
  218.         endif
  219.         shell "" DoNewInstall
  220.         ifstr(i) $($R0) == "STATUS_BACK"
  221.             goto poseSetupType
  222.         else-ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  223.             goto setupnotdone
  224.         else
  225.             read-syms InstalledTag$(!STF_LANGUAGE)
  226.             goto installdone
  227.         endif
  228.     else-ifstr(i) $(!InstallType) == "2"
  229.         shell "" DoTestSMS
  230.         ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  231.             read-syms SMSConflict$(!STF_LANGUAGE)
  232.             set !Addl95Text = " "
  233.             goto setupnotdone
  234.         endif
  235.         shell "" DoTestUpgradeVersion
  236.         ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  237.             read-syms FailedUserSetupQuit$(!STF_LANGUAGE)
  238.             set !Addl95Text = " "
  239.             goto setupnotdone
  240.         endif
  241.         shell "" DoUpgrade
  242.         ifstr(i) $($R0) == "STATUS_BACK"
  243.             goto poseSetupType
  244.         else-ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  245.             goto setupnotdone
  246.         else
  247.             read-syms UpgradedTag$(!STF_LANGUAGE)
  248.             ifstr(i) $(!Remote) == "TRUE"
  249.                 shell "" DoDelete95Key $(!RemoteComputer),"DELOLD"
  250.             else
  251.                 ifstr(i) $(!KeysDupped) == "TRUE"
  252.                     shell "" DoDelete95Key $(!ComputerName),"DELOLD"
  253.                 endif
  254.             endif
  255.             goto installdone
  256.         endif
  257.     else-ifstr(i) $(!InstallType) == "3"
  258.         shell "" DoInstallUtils
  259.         ifstr(i) $($R0) == "STATUS_BACK"
  260.             goto poseSetupType
  261.         else-ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  262.             goto setupnotdone
  263.         else
  264.             read-syms UtilInstallTag$(!STF_LANGUAGE)
  265.             goto installdone
  266.         endif
  267.     else-ifstr(i) $(!InstallType) == "4"
  268.         shell "" DoNetInstall
  269.         ifstr(i) $($R0) == "STATUS_BACK"
  270.             goto poseSetupType
  271.         else-ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  272.             goto setupnotdone
  273.         else
  274.             read-syms STR_CompletionNetworks
  275.         endif
  276.     else-ifstr(i) $(!InstallType) == "5"
  277.         shell "" RestoreOldClientKey
  278.         shell "" DoInstallLang
  279.         ifstr(i) $($R0) == "STATUS_BACK"
  280.             goto poseSetupType
  281.         else-ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  282.             goto setupnotdone
  283.         else
  284.             read-syms CompletionLangInst$(!STF_LANGUAGE)
  285.         endif
  286.     else-ifstr(i) $(!InstallType) == "6"
  287.         read-syms RebuildError$(!STF_LANGUAGE)
  288.         shell "" RestoreOldClientKey
  289.         shell "" DoRebuildDatabase
  290.         ifstr(i) $($R0) == "STATUS_BACK"
  291.             goto poseSetupType
  292.         else-ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  293.             goto setupnotdone
  294.         else
  295.             read-syms CompletionNewCharSort$(!STF_LANGUAGE)
  296.         endif
  297.     else-ifstr(i) $(!InstallType) == "7"
  298.         shell "" RestoreOldClientKey
  299.         shell "" DoServerOptions
  300.         ifstr(i) $($R0) == "STATUS_BACK"
  301.             goto poseSetupType
  302.         else-ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  303.             goto setupnotdone
  304.         else
  305.             read-syms CompletionOptions$(!STF_LANGUAGE)
  306.         endif
  307.     else-ifstr(i) $(!InstallType) == "8"
  308.         shell "" RestoreOldClientKey
  309.         shell "" DoGetSecurityOptions
  310.         ifstr(i) $($R0) == "STATUS_BACK"
  311.             goto poseSetupType
  312.         else-ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  313.             goto setupnotdone
  314.         else
  315.             read-syms STR_CompletionSecurity
  316.         endif
  317.     else-ifstr(i) $(!InstallType) == "9"
  318.         shell "" DoNuke
  319.         ifstr(i) $($R0) == "STATUS_BACK"
  320.             goto poseSetupType
  321.         else-ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  322.             goto setupnotdone
  323.         else
  324.             ifstr(i) $(!RemoteComputer) == ""
  325.                 read-syms CompletionNuked$(!STF_LANGUAGE)
  326.             else
  327.                 read-syms CompletionNukedRemote$(!STF_LANGUAGE)
  328.             endif
  329.         endif
  330.     endif
  331.     
  332. setupdone =+
  333.     set Exit_Code = $(!SETUP_ERROR_SUCCESS)
  334. setupnotdone =+
  335.     ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  336.         ifstr(i) $(!SQL95Keys) != "TRUE"
  337.             ifstr(i) $(!RemoteComputer) != ""
  338.                 ifstr(i) $(!RemoteKeysDupped) == "TRUE"
  339.                     shell "" DoDelete95Key $(!RemoteComputer), ""
  340.                 endif
  341.             else
  342.                 ifstr(i) $(!KeysDupped) == "TRUE"
  343.                     shell "" DoDelete95Key $(!ComputerName), ""
  344.                 endif
  345.             endif
  346.         endif
  347.         ifstr(i) $(!LicenseWritten) == "TRUE"
  348.             ifstr(i) $(!InstallType) != "2"
  349.                 shell "" DoLicenseNuke
  350.             else
  351.                 ifstr(i) $(!KeysDupped) == "TRUE"
  352.                     shell "" DoLicenseNuke
  353.                 endif
  354.             endif
  355.         endif
  356.     endif
  357.     ifstr(i) $(!RegValSQL95KeyDB) != ""
  358.         LibraryProcedure OpenParamKey, $(!DLLSQL), RegMakeKey "\\"$(!ComputerName),$(!RegSQLServer)"\"$(!RegSQLServerSvr),$(!RegSQLSvrParam),$(!AdminACL)
  359.         LibraryProcedure Result, $(!DLLSQL), RegDelValue $(OpenParamKey),$(!RegValSQL95KeyDB)
  360.         LibraryProcedure Result, $(!DLLSQL), RegClose $(OpenParamKey)
  361.     endif
  362.     ifstr(i) $(!WasSingleMode) == "NO"
  363.         ifstr(i) $(!RegValSingleUserArg) != ""
  364.             LibraryProcedure !OpenParamKey, $(!DLLSQL), RegMakeKey "\\"$(!ComputerName),$(!RegSQLServerServer),$(!RegSQLSvrParam),$(!AdminACL)
  365.             LibraryProcedure Result, $(!DLLSQL), RegDelValue $(!OpenParamKey),$(!RegValSingleUserArg)
  366.             LibraryProcedure Result, $(!DLLSQL), RegClose $(!OpenParamKey)
  367.         endif
  368.     endif
  369.     ifstr(i) $(!STF_OS) == "NT"
  370.         ifstr(i) $(!NonCriticalScriptFailure) == ""
  371.             ifstr(i) $(!NonCriticalODBCInstallFail) == ""
  372.                 ifstr(i) $(!Addl95Text) == ""
  373.                     set !AddlText = ""
  374.                 endif
  375.             else
  376.                 read-syms ODBCInstallFail$(!STF_LANGUAGE)
  377.             endif
  378.         else
  379.             read-syms STR_NonCriticalScriptFail
  380.         endif
  381.     endif
  382.     ifstr(i) $(!Addl95Text) == ""
  383.         read-syms SetupDoneDlg$(!STF_LANGUAGE)
  384.     else
  385.         read-syms SetupDoneDlg95$(!STF_LANGUAGE)
  386.     endif
  387.     LibraryProcedure DlgDone, $(!DLLSQL), SQLDlgDisplay $(STF_HWND),$(DlgTemplate),"",$(!SQLDlgNames),"",""
  388. setnotdone_wait =+
  389.     LibraryProcedure DLGEVENT, $(!DLLSQL), WaitEvent
  390.     ifstr(i) $(DLGEVENT) != "DLGBUTTON1"
  391.         goto setnotdone_wait
  392.     endif
  393.     LibraryProcedure Result, $(!DLLSQL), CloseDialog $(DlgDone)
  394.     goto end
  395.     
  396. installdone =+
  397.     set Exit_Code = $(!SETUP_ERROR_SUCCESS)
  398.     ifstr(i) $(!RemoteComputer) == ""
  399.         read-syms InstallCompletedLocal$(!STF_LANGUAGE)
  400.     else
  401.         read-syms InstallCompletedRemote$(!STF_LANGUAGE)
  402.     endif
  403.     ifstr(i) $(!STF_OS) == "NT"
  404.         ifstr(i) $(!NonCriticalScriptFailure) == ""
  405.             ifstr(i) $(!NonCriticalODBCInstallFail) == ""
  406.                 set !AddlText = ""
  407.             else
  408.                 read-syms ODBCInstallFail$(!STF_LANGUAGE)
  409.             endif
  410.         else
  411.             read-syms STR_NonCriticalScriptFail
  412.         endif
  413.     endif
  414.     
  415.     ifstr(i) $(!IniFilePath) == ""
  416.         read-syms InstallCompleted$(!STF_LANGUAGE)
  417.         LibraryProcedure DlgDone, $(!DLLSQL), SQLDlgDisplay $(STF_HWND),$(DlgTemplate),"",$(!SQLDlgNames),"",""
  418. installdone_wait =+
  419.         LibraryProcedure DLGEVENT, $(!DLLSQL), WaitEvent
  420.         ifstr(i) $(DLGEVENT) == "DLGBUTTON1"
  421.             LibraryProcedure Result, $(!DLLSQL), CloseDialog $(DlgDone)
  422.             goto end
  423.         else-ifstr(i) $(DLGEVENT) == "DLGBUTTON2"
  424.             LibraryProcedure Result, $(!DLLSQL), CloseDialog $(DlgDone)
  425.             goto rebootend
  426.         else
  427.             goto installdone_wait
  428.         endif
  429.     else
  430.         LibraryProcedure bReboot, $(!DLLSQL), GetPrivProfStr "Scripts", "ForceReboot", $(!IniFilePath)
  431.         ifstr(i) $(bReboot) == "TRUE"
  432.             goto rebootend
  433.         else
  434.             goto end
  435.         endif
  436.     endif
  437.     
  438. rebootend =+
  439.     install Install-Shutdown
  440.     
  441. end =+
  442.     ifstr(i) $(!RemoteSQLDrive) != ""
  443.         LibraryProcedure Result, $(!DLLSQL), NETDriveOperation "DISCONNECT","","",$(!RemoteSQLDrive)
  444.     endif
  445.     ifstr(i) $(!RemoteNTDrive) != ""
  446.         LibraryProcedure Result, $(!DLLSQL), NETDriveOperation "DISCONNECT","","",$(!RemoteNTDrive)
  447.     endif
  448.     ifstr(i) $(!RemoteDBDrive) != ""
  449.         LibraryProcedure Result, $(!DLLSQL), NETDriveOperation "DISCONNECT","","",$(!RemoteDBDrive)
  450.     endif
  451.     ifstr(i) $(!STF_OS) == "NT"
  452.         LibraryProcedure Result, $(!DLLSQL), DeleteSecurityAttribute $(!AdminACL)
  453.     endif
  454.     ifstr(i) $(!ClientModKey) != ""
  455.         shell "" RestoreOldClientKey
  456.         LibraryProcedure Result, $(!DLLSQL), RegClose $(!ClientModKey)
  457.     endif
  458.     LibraryProcedure Result, $(!DLLSQL), SQLDLLFinish
  459.     install FreeSetupLibrary
  460.     exit
  461.     
  462. [RestoreOldClientKey]
  463.     ifstr(i) $(!ClientModKey) != ""
  464.         ifstr(i) $(!OldDSQuery) != ""
  465.             LibraryProcedure Result, $(!DLLSQL), RegSet $(!ClientModKey),$(!RegValDSQUERY),$(!RegTypeString),$(!OldDSQuery),""
  466.         endif
  467.         shell "" RestoreOldAliasName
  468.     endif
  469.     return
  470.         
  471. [GetAliasConnectTo]
  472.     set !OldMachineAlias = ""
  473.     LibraryProcedure ClientKey, $(!DLLSQL), RegOpen "\\"$(!ComputerName),$(!RegSQLClient)"\"$(!RegSQLConnectTo)
  474.     ifstr(i) $(ClientKey) == "KEY_ERROR"
  475.         LibraryProcedure ClientKey, $(!DLLSQL), RegOpen "\\"$(!ComputerName),$(!RegOldSQLClient)"\"$(!RegSQLConnectTo)
  476.     endif
  477.     ifstr(i) $(ClientKey) != "KEY_ERROR"
  478.         LibraryProcedure !OldMachineAlias, $(!DLLSQL), RegRead $(ClientKey),$($0)
  479.         ifstr(i) $(!OldMachineAlias) == "KEY_ERROR"
  480.             set !OldMachineAlias = ""
  481.             set !OldComputerName = ""
  482.         else
  483.             ifstr(i) $(ClientKey) != ""
  484.                 LibraryProcedure Result, $(!DLLSQL), RegClose $(ClientKey)
  485.             endif
  486.             set ClientKey = ""
  487.             ifstr(i) $(!ClientModKey) == ""
  488.                 LibraryProcedure !ClientModKey, $(!DLLSQL), RegMakeKey "\\"$(!ComputerName),$(!RegSQLClient),$(!RegSQLConnectTo),""
  489.             endif
  490.             ifstr(i) $(ClientModKey) == "KEY_ERROR"
  491.                 LibraryProcedure !ClientModKey, $(!DLLSQL), RegMakeKey "\\"$(!ComputerName),$(!RegOldSQLClient),$(!RegSQLConnectTo),""
  492.             endif
  493.             ifstr(i) $(ClientModKey) == "KEY_ERROR"
  494.                 set !ClientModKey = ""
  495.             else
  496.                 LibraryProcedure Result, $(!DLLSQL), RegDelValue $(!ClientModKey),$($0)
  497.                 set !OldComputerName = $($0)
  498.             endif
  499.         endif
  500.         ifstr(i) $(ClientKey) != ""
  501.             LibraryProcedure Result, $(!DLLSQL), RegClose $(ClientKey)
  502.         endif
  503.     endif
  504.     Return
  505.     
  506. [RestoreOldAliasName]
  507.     ifstr(i) $(!ClientModKey) != ""
  508.         ifstr(i) $(!OldMachineAlias) != ""
  509.             LibraryProcedure Result, $(!DLLSQL), RegSet $(!ClientModKey),$(!OldComputerName),$(!RegTypeString),$(!OldMachineAlias),""
  510.         endif
  511.     endif
  512.     Return
  513.     
  514. [DoTestUpgradeVersion]
  515.     set Status = "STATUS_FAILED"
  516.     set CompVal = ""
  517.     ifstr(i) $(!CurInstalledVer) == ""
  518.         set Status = "STATUS_SUCCESSFUL"
  519.         goto endDoTestVers
  520.     endif
  521.     LibraryProcedure MainVer, $(!DLLSQL), StrBeforeAndAfter $(!CurInstalledVer),"BEFORE","."
  522.     ifstr(i) $(MainVer) != "6"
  523.         ifstr(i) $(MainVer) == "NT 4"
  524.             set Status = "STATUS_SUCCESSFUL"
  525.             goto endDoTestVers
  526.         endif
  527.     else
  528.         LibraryProcedure CompVal $(!DLLSQL), CompareVersions, $(!MinUpgradeVersion), $(!CurInstalledVer)
  529.         ifstr(i) $(CompVal) == "<"
  530.             set Status = "STATUS_SUCCESSFUL"
  531.         else-ifstr(i) $(CompVal) == "="
  532.             set Status = "STATUS_SUCCESSFUL"
  533.         endif
  534.         ifstr(i) $(Status) == "STATUS_SUCCESSFUL"
  535.             set !MarketBetaUpgrade = "FALSE"
  536.         endif
  537.     endif
  538. endDoTestVers =+
  539.     ifstr(i) $(Status) != "STATUS_SUCCESSFUL"
  540.         read-syms CantUpgradeBetaDlg$(!STF_LANGUAGE)
  541.         LibraryProcedure SetupTypeDlg, $(!DLLSQL), SQLDlgDisplay $(STF_HWND),$(!DlgTemplate),"",$(!SQLDlgNames),"MODAL",""
  542. waitTestVer =+
  543.         LibraryProcedure DLGEVENT, $(!DLLSQL), WaitEvent
  544.         ifstr(i) $(DLGEVENT) == "CONTINUE"
  545.             LibraryProcedure Result, $(!DLLSQL), CloseDialog $(SetupTypeDlg)
  546.         else
  547.             goto waitTestVer
  548.         endif
  549.     endif
  550.     Return $(Status)
  551.     
  552. [DoTestMachineName]
  553.     set Status = "STATUS_SUCCESSFUL"
  554.     LibraryProcedure Results, $(!DLLSQL), IsValidMachineName $($0)
  555.     ifstr(i) $(Results) == "FALSE"
  556.         read-syms InvalidMachineName$(!STF_LANGUAGE)
  557.         LibraryProcedure DlgInvalid, $(!DLLSQL), SQLDlgDisplay $(STF_HWND),$(!DlgTemplate),"",$(!SQLDlgNames),"",""
  558. invalidcont =+
  559.         LibraryProcedure DLGEVENT, $(!DLLSQL), WaitEvent
  560.         ifstr(i) $(DLGEVENT) == "CONTINUE"
  561.             set Status = "STATUS_SUCCESSFUL"
  562.         else-ifstr(i) $(DLGEVENT) == "EXIT"
  563.             shell "" QueryUserQuit $(!STF_LANGUAGE)
  564.             ifstr(i) $($R1) == "OK"
  565.                 set Status = "STATUS_USERQUIT"
  566.             else
  567.                 goto invalidcont
  568.             endif
  569.         endif
  570.         LibraryProcedure Result, $(!DLLSQL), CloseDialog $(DlgInvalid)
  571.     else
  572.         set Status = "STATUS_SUCCESSFUL"
  573.     endif
  574.     Return $(Status)
  575.     
  576. [QueryUserQuit]
  577.     set Status     = "STATUS_FAILED"
  578.     set UserAction = CANCEL
  579.     read-syms ExitWarningDlg$(!STF_LANGUAGE)
  580.     ui start "ExitWarning"
  581.     ifstr(i) $(DLGEVENT) == "YES"
  582.         set Status     = "STATUS_SUCCESSFUL"
  583.         set UserAction = "OK"
  584.         read-syms FailedUserQuit$(!STF_LANGUAGE)
  585.         set !MsgText = $(!AddlText)
  586.         set !AddlText = ""
  587.     else-ifstr(i) $(DLGEVENT) == "NO"
  588.         set Status     = "STATUS_SUCCESSFUL"
  589.         set UserAction = "CANCEL"
  590.     endif
  591.     Return $(Status) $(UserAction)
  592.     
  593. [DoSelectClientInstall]
  594.     LibraryProcedure Key, $(!DLLSQL), RegOpen "",$(!RegSQLClientSetup)
  595.     ifstr(i) $(Key) != "KEY_ERROR"
  596.         LibraryProcedure !SQLPath, $(!DLLSQL), RegRead $(Key),$(!RegValSQLPath)
  597.         ifstr(i) $(!SQLPath) != "KEY_ERROR"
  598.             set !ClientInstallKey = "TRUE"
  599.         endif
  600.         LibraryProcedure Result, $(!DLLSQL), RegClose $(Key)
  601.         set !DefSQLPath = $(!SQLPath)
  602.         LibraryProcedure !ClientInstallDrive, $(!DLLSQL), StrBeforeAndAfter $(!SQLPath),"BEFORE","\"
  603.     endif
  604.     StartWait
  605.     set Status = "STATUS_FAILED"
  606.     read-syms SelectClientInstallDlg$(!STF_LANGUAGE)
  607.     LibraryProcedure SetupTypeDlg, $(!DLLSQL), SQLDlgDisplay $(STF_HWND),$(!DlgTemplate),"",$(!SQLDlgNames),"MODAL",""
  608.     ifstr(i) $(!ClientInstallKey) == "TRUE"
  609.         LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(SetupTypeDlg),"UNIBUTTON1","TRUE"
  610.         LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(SetupTypeDlg),"UNIBUTTON2","TRUE"
  611.         LibraryProcedure Result, $(!DLLSQL), DlgCheckButton $(SetupTypeDlg),"UNIBUTTON2","TRUE"
  612.         LibraryProcedure Result, $(!DLLSQL), DlgCheckButton $(SetupTypeDlg),"UNIBUTTON1","FALSE"
  613.     else
  614.         LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(SetupTypeDlg),"UNIBUTTON1","TRUE"
  615.         LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(SetupTypeDlg),"UNIBUTTON2","FALSE"
  616.         LibraryProcedure Result, $(!DLLSQL), DlgCheckButton $(SetupTypeDlg),"UNIBUTTON1","TRUE"
  617.         LibraryProcedure Result, $(!DLLSQL), DlgCheckButton $(SetupTypeDlg),"UNIBUTTON2","FALSE"
  618.     endif
  619.     clisetuptype = +
  620.     EndWait
  621.     LibraryProcedure DLGEVENT, $(!DLLSQL), WaitEvent
  622.     ifstr(i) $(DLGEVENT) == "CONTINUE"
  623.         set Status = "STATUS_SUCCESSFUL"
  624.         LibraryProcedure CliInstallType, $(!DLLSQL), GetCheckedRadio $(SetupTypeDlg)
  625.         ifstr(i) $(CliInstallType) == "2"
  626.             set !InstallType = "9"
  627.         else
  628.             set !InstallType = "3"
  629.         endif
  630.     else-ifstr(i) $(DLGEVENT) == "EXIT"
  631.         shell "" QueryUserQuit $(!STF_LANGUAGE)
  632.         ifstr(i) $($R1) == "OK"
  633.             set Status = "STATUS_USERQUIT"
  634.         else
  635.             goto clisetuptype
  636.         endif
  637.     else
  638.         goto clisetuptype
  639.     endif
  640.     LibraryProcedure Result, $(!DLLSQL), CloseDialog $(SetupTypeDlg)
  641. endCliSetupType =+
  642.     Return $(Status)
  643.         
  644. [DoTestSQLServer60]
  645.     set Status = "STATUS_FAILED"
  646.     LibraryProcedure TestKey, $(!DLLSQL), RegOpen "\\"$(!ComputerName),$(!RegSQLServer60Server)
  647.     ifstr(i) $(TestKey) == "KEY_ERROR"
  648.         set Status = "STATUS_SUCCESSFUL"
  649.     else
  650.         LibraryProcedure Result, $(!DLLSQL), RegClose $(TestKey)
  651.     endif
  652.     Return $(Status)
  653.     
  654. [DoTestSMS]
  655.     set Status = "STATUS_SUCCESSFUL"
  656.     LibraryProcedure TestKey, $(!DLLSQL), RegOpen "\\"$(!ComputerName),$(!SMSVersionKey)
  657.     ifstr(i) $(TestKey) != "KEY_ERROR"
  658.         LibraryProcedure SMSVersion, $(!DLLSQL), RegRead $(TestKey),$(!RegValSMSVersion)
  659.         ifstr(i) $(SMSVersion) != "KEY_ERROR"
  660.             ifint $(SMSVersion) < "632"
  661.                 read-syms UpgradeOverSMS$(!STF_LANGUAGE)
  662.                 shell "" UpgradeQ
  663.                 set Status = $($R0)
  664.             endif
  665.         endif
  666.         LibraryProcedure Result, $(!DLLSQL), RegClose $(TestKey)
  667.     endif
  668.     Return $(Status)
  669.         
  670. [DoClearInstallVars]
  671.     set !Owner = ""
  672.     set !Organiz = ""
  673.     set !MasterDBFileName = ""
  674.     set !IntegratedSecurity = ""
  675.     set !MultipleNetworkSupport = ""
  676.     set !CurInstalledVer = ""
  677.     set !OldSQLPath = $(!SQLPath)
  678.     set !SQLPath = ""
  679.     ifstr(i) $(!RemoteComputer) == ""
  680.         set !LogicalSQLDrive = ""
  681.         set !RemoteDBDrive = ""
  682.         set !LogicalDBDrive = ""
  683.         set !DefSQLPath = $(!RemoteSQLDrive)"\"$(!DefSQLStub)
  684.     else
  685.         set !DefSQLPath = $(!Primary)"\"$(!DefSQLStub)
  686.     endif
  687.     Return
  688.         
  689. [DoDupKeys]
  690.     set Status = "STATUS_FAILED"
  691.     ifstr(i) $(!SQL95Key) == "TRUE"
  692.         set Status = "STATUS_SUCCESSFUL"
  693.         goto endkeys
  694.     endif
  695.     LibraryProcedure,OldKey,$(!DLLSQL),RegOpen "\\"$(!ComputerName),$(!RegOldSQLServerServer)
  696.     ifstr(i) $(OldKey) == "KEY_ERROR"
  697.         set !NewInstall = "TRUE"
  698.         set Status = "STATUS_NOTDUP"
  699.         goto endkeys
  700.     endif
  701.     LibraryProcedure,Results,$(!DLLSQL),RegClose $(OldKey)
  702.     ifstr(i) $(!RemoteComputer) != ""
  703.         LibraryProcedure,Results,$(!DLLSQL),RegDupKey "\\"$(!ComputerName),"C:",$(!RemoteNTDrive),$(!RegOldSQLServer),$(!RegSQLServer)
  704.     else
  705.         LibraryProcedure,Results,$(!DLLSQL),RegDupKey "\\"$(!ComputerName),"C:","C:",$(!RegOldSQLServer),$(!RegSQLServer)
  706.     endif
  707.     ifstr(i) $(Result) != ""
  708.         read-syms DupKeyError$(!STF_LANGUAGE)
  709.         return $(Status)
  710.     endif
  711.     ifstr(i) $(!RemoteComputer) != ""
  712.         LibraryProcedure,Results,$(!DLLSQL),RegDupKey "\\"$(!ComputerName),"C:",$(!RemoteNTDrive),$(!RegOldSQLServerServer),$(!RegSQLServerServer)
  713.     else
  714.         LibraryProcedure,Results,$(!DLLSQL),RegDupKey "\\"$(!ComputerName),"C:","C:",$(!RegOldSQLServerServer),$(!RegSQLServerServer)
  715.     endif
  716.     ifstr(i) $(Result) != ""
  717.         read-syms DupKeyError$(!STF_LANGUAGE)
  718.         return $(Status)
  719.     else
  720.         set Status = "STATUS_SUCCESSFUL"
  721.         set OldMail = {}
  722.         LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$(!ComputerName),"UNIDELETE",$(!RegSQLServer)"\"$(!RegOldSQLServerSvr),$(!RegSQLServerVer)
  723.         LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$(!ComputerName),"UNIDELETE",$(!RegSQLServer)"\"$(!RegOldSQLServerSvr),$(!RegSQLSvrParam)
  724.         LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$(!ComputerName),"UNIDELETE",$(!RegSQLServer),$(!RegOldSQLServerSvr)
  725.         LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$(!ComputerName),"UNIDELETE",$(!RegSQLServer),$(!SQLMonitorService)"\"$(!RegSQLSvrParam)
  726.         LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$(!ComputerName),"UNIDELETE",$(!RegSQLServer),$(!SQLMonitorService)
  727.         LibraryProcedure OpenParamKey, $(!DLLSQL), RegMakeKey "\\"$(!ComputerName),$(!RegSQLServer),$(!RegSQLServerSvr),$(!AdminACL)
  728.         LibraryProcedure !OldListenOn, $(!DLLSQL), RegRead $(OpenParamKey),$(!RegValListenOn)
  729.         LibraryProcedure !OldListenOn $(!DLLSQL),UpdateNetlibStrings,$(!OldListenOn)
  730.         LibraryProcedure Result, $(!DLLSQL), RegDelValue $(OpenParamKey),$(!RegValListenOn)
  731.         LibraryProcedure Result, $(!DLLSQL), RegDelValue $(OpenParamKey),$(!RegValSMPStat)
  732.         LibraryProcedure Result, $(!DLLSQL), RegDelValue $(OpenParamKey),$(!RegValRealTime)
  733.         LibraryProcedure OldMail, $(!DLLSQL), RegRead $(OpenParamKey),$(!RegValMailEnabled)
  734.         ifstr(i) $(OldMail) != "KEY_ERROR"
  735.             set NewMail = {}
  736.             ForListDo $(OldMail)
  737.                 ifstr(i) $($) == $(!OldSQLMapi)
  738.                     set NewMail = >( $(NewMail),$(!RegValSqlMailPair))
  739.                 else
  740.                     set NewMail = >( $(NewMail),$($) )
  741.                 endif
  742.             EndForListDo
  743.             LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenParamKey),$(!RegValMailEnabled),$(!RegTypeMulti),$(NewMail),""
  744.         endif
  745.         LibraryProcedure Result, $(!DLLSQL), RegClose $(OpenParamKey)
  746.     endif
  747. endkeys =+
  748.     return $(Status)
  749.         
  750. [DoAdminCheck]
  751.     set Status = "STATUS_FAILED"
  752.     LibraryProcedure Result, $(!DLLSQL), IsAdmin
  753.     ifstr(i) $(Result) == "ACCESS_DENIED"
  754.         read-syms InsufficientPriv
  755.         LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)
  756.         goto admin_end
  757.     endif
  758.     ifstr(i) $(!StandAlone) == ""
  759.         shell "" StartService $(!LANManService)
  760.         ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  761.             goto admin_end
  762.         endif
  763.     endif
  764.     set Status = "STATUS_SUCCESSFUL"
  765. admin_end =+
  766.     Return $(Status)
  767.         
  768. [DoCheckOS]
  769.     set Status = "STATUS_FAILED"
  770.     ifstr(i) $(!STF_OS) != "NT"
  771.         set Status = "STATUS_SUCCESSFUL"
  772.         set !RdrCopy = "FALSE"
  773.         goto checkos_done
  774.     endif
  775.     LibraryProcedure Result, $(!DLLSQL), VerifyNTVersion $(!MinOSVersion)
  776.     ifstr(i) $(Result) == ""
  777.         set Status = "STATUS_SUCCESSFUL"
  778.     else
  779.         read-syms STR_InferiorOS
  780.         set !MsgText = $(!AddlText)
  781.     endif
  782.     LibraryProcedure Key, $(!DLLSQL), RegOpen "\\"$(!ComputerName),$(!RegSQLWinNT)
  783.     ifstr(i) $(Key) != "KEY_ERROR"
  784.         LibraryProcedure !BuildNumber, $(!DLLSQL), RegRead $(Key),$(!RegValCurBuild)
  785.         LibraryProcedure Result, $(!DLLSQL), RegClose $(Key)
  786.         ifstr(i) $(!BuildNumber) != "KEY_ERROR"
  787.             ifstr(i) $(!RemoteComputer) == ""
  788.                 set !LocalBuildNumber = $(!BuildNumber)
  789.             endif
  790.             ifint $(!BuildNumber) > $(!RdrMinOSVersion)
  791.                 set Result = ""
  792.             else
  793.                 set Result = "FALSE"
  794.             endif
  795.         else
  796.             LibraryProcedure Result, $(!DLLSQL), VerifyNTVersion $(!RdrMinOSVersion)
  797.         endif
  798.     else
  799.         LibraryProcedure Result, $(!DLLSQL), VerifyNTVersion $(!RdrMinOSVersion)
  800.     endif
  801.     ifstr(i) $(Result) != ""
  802.         LibraryProcedure Result, $(!DLLSQL), IsWorkStationStarted
  803.         ifstr(i) $(Result) == "TRUE"
  804.             set !RdrCopy = "TRUE"
  805.         else
  806.             set !RdrCopy = "FALSE"
  807.         endif
  808.     else
  809.         set !RdrCopy = "FALSE"
  810.     endif
  811. checkos_done =+
  812.     Return $(Status)
  813.         
  814. [DoCheckServerKeyAccess]
  815.     set Status = "STATUS_FAILED"
  816.     LibraryProcedure Result, $(!DLLSQL), IsAdmin
  817.     ifstr(i) $(Result) != "ACCESS_DENIED"
  818.         LibraryProcedure NewSvrKey, $(!DLLSQL), RegMakeKey "\\"$(!ComputerName),$(!RegSQLServer),"",
  819.         ifstr(i) $(NewSvrKey) != "KEY_ERROR"
  820.             LibraryProcedure TmpKey, $(!DLLSQL), RegMakeKey "\\"$(!ComputerName),$(!RegSQLServer)"\Test","",$(!AdminACL)
  821.             ifstr(i) $(TmpKey) != "KEY_ERROR"
  822.                 LibraryProcedure Result, $(!DLLSQL), RegClose $(TmpKey)
  823.                 LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$(!ComputerName),"UNIDELETE",$(!RegSQLServer),"Test"
  824.                 set Status = "STATUS_SUCCESSFUL"
  825.             else
  826.                 read-syms STR_InvalidSystemAdmin
  827.                 set !MsgText = $(!AddlText)
  828.             endif
  829.             LibraryProcedure Result, $(!DLLSQL), RegClose $(NewSvrKey)
  830.         else
  831.             read-syms STR_InvalidSystemAdmin
  832.             set !MsgText = $(!AddlText)
  833.         endif
  834.     else
  835.         set Status = "STATUS_SUCCESSFUL"
  836.     endif
  837.     Return $(Status)
  838.         
  839. [DoWelcome]
  840.     set Status = "STATUS_SUCCESSFUL"
  841.     ifstr(i) $(!IniFilePath) == ""
  842.         set Status = "STATUS_FAILED"
  843.         read-syms WelcomeDlg$(!STF_LANGUAGE)
  844.         LibraryProcedure DlgWelcome, $(!DLLSQL), SQLDlgDisplay $(STF_HWND),$(DlgTemplate),"",$(!SQLDlgNames),"MODAL",""
  845.         welcome = +
  846.         LibraryProcedure DLGEVENT, $(!DLLSQL), WaitEvent
  847.         ifstr(i) $(DLGEVENT) == "CONTINUE"
  848.             set Status = "STATUS_SUCCESSFUL"
  849.         else-ifstr(i) $(DLGEVENT) == "EXIT"
  850.             shell "" QueryUserQuit $(!STF_LANGUAGE)
  851.             ifstr(i) $($R1) == "OK"
  852.                 set Status = "STATUS_USERQUIT"
  853.             else
  854.                 goto welcome
  855.             endif
  856.         endif
  857.         LibraryProcedure Result, $(!DLLSQL), CloseDialog $(DlgWelcome)
  858.     endif
  859.     Return $(Status)
  860.         
  861. [DoAlreadyInstalled]
  862.     set Status = "STATUS_FAILED"
  863.     read-syms AlreadyInstalledDlg$(!STF_LANGUAGE)
  864.     LibraryProcedure DlgAlready, $(!DLLSQL), SQLDlgDisplay $(STF_HWND),$(DlgTemplate),"",$(!SQLDlgNames),"",""
  865. already =+
  866.     LibraryProcedure DLGEVENT, $(!DLLSQL), WaitEvent
  867.     ifstr(i) $(DLGEVENT) == "CONTINUE"
  868.         set Status = "STATUS_SUCCESSFUL"
  869.     else-ifstr(i) $(DLGEVENT) == "CALLCOMBOKILLFOCUS1"
  870.         goto already
  871.     endif
  872.     LibraryProcedure Result, $(!DLLSQL), CloseDialog $(DlgAlready)
  873.     Return $(Status)
  874.         
  875. [GetPreviousInstallationInfo]
  876.     set !Owner = ""
  877.     set !Organiz = ""
  878.     set !MasterDBFileName = ""
  879.     set !Registration = ""
  880.     set !IntegratedSecurity = ""
  881.     set !MultipleNetworkSupport = ""
  882.     set !CurInstalledVer = ""
  883.     LibraryProcedure Key, $(!DLLSQL), RegOpen "\\"$(!ComputerName),$(!RegSQLServerServer)"\"$(!RegSQLServerVer)
  884.     ifstr(i) $(Key) == "KEY_ERROR"
  885.         LibraryProcedure Key, $(!DLLSQL), RegOpen "\\"$(!ComputerName),$(!RegOldSQLServerServer)"\"$(!RegSQLServerVer)
  886.     endif
  887.     ifstr(i) $(Key) != "KEY_ERROR"
  888.         LibraryProcedure !Owner, $(!DLLSQL), RegRead $(Key),$(!RegValRegOwner)
  889.         LibraryProcedure !Organiz, $(!DLLSQL), RegRead $(Key),$(!RegValRegOrg)
  890.         LibraryProcedure !ProductID, $(!DLLSQL), RegRead $(Key),$(!RegValRegPID)
  891.         LibraryProcedure !CurInstalledVer, $(!DLLSQL), RegRead $(Key),$(!RegSQLServerVer)
  892.         ifstr(i) $(!ProductID) == "KEY_ERROR"
  893.             set !ProductID = ""
  894.         endif
  895.         ifstr(i) $(!Organiz) == "KEY_ERROR"
  896.             set !Owner = ""
  897.             goto prevDisplay
  898.         endif
  899.         
  900.         set !FullName = $(!Owner)
  901.         set !OrgName = $(!Organiz)
  902.         set !Registration = $(!Owner)" - "$(!Organiz)
  903.         LibraryProcedure Result, $(!DLLSQL), RegClose $(Key)
  904.         
  905.         shell "" RegGetSecuritySupport
  906.         ifstr(i) $($R0) == "STATUS_SUCCESSFUL"
  907.             ifstr(i) $($R1) == "2"
  908.                 set !IntegratedSecurity = "TRUE"
  909.             endif
  910.         endif
  911.         
  912.         LibraryProcedure OpenServerKey, $(!DLLSQL), RegOpen "\\"$(!ComputerName),$(!RegSQLServer)"\"$(!RegSQLServerSvr)
  913.         ifstr(i) $(OpenServerKey) != "KEY_ERROR"
  914.             LibraryProcedure ListenOn, $(!DLLSQL), RegRead $(OpenServerKey),$(!RegValListenOn)
  915.             ifstr(i) $(ListenOn) != "KEY_ERROR"
  916.                 QueryListSize NumArgs $(ListenOn)
  917.                 ifint $(NumArgs) > "1"
  918.                     ForListDo $(ListenOn)
  919.                         ifstr(i) $($) == $(!NetLibRPC)
  920.                             ifint $(NumArgs) == "2"
  921.                                 set !MultipleNetworkSupport = ""
  922.                             else
  923.                                 set !MultipleNetworkSupport = "TRUE"
  924.                             endif
  925.                         else
  926.                             set !MultipleNetworkSupport = "TRUE"
  927.                         endif
  928.                     EndForListDo
  929.                 endif
  930.             endif
  931.             LibraryProcedure !MSMailUser, $(!DLLSQL), RegRead $(OpenServerKey),$(!RegValMSMailUser)
  932.             ifstr(i) $(!MSMailUser) == "KEY_ERROR"
  933.                 set !MSMailUser = ""
  934.                 set !MSMailPwd = ""
  935.             else
  936.                 LibraryProcedure !MSMailPwd, $(!DLLSQL), RegRead $(OpenServerKey),$(!RegValMSMailPwd)
  937.             endif
  938.             LibraryProcedure Result, $(!DLLSQL), RegClose $(OpenServerKey)
  939.         endif
  940.         LibraryProcedure OpenServerKey, $(!DLLSQL), RegOpen "\\"$(!ComputerName),$(!RegSQLServerServer)"\"$(!RegRPCNetLib)
  941.         ifstr(i) $(OpenServerKey) != "KEY_ERROR"
  942.             LibraryProcedure !MultiProtEncrypt, $(!DLLSQL), RegRead $(OpenServerKey),$(!RegValRPCSec)
  943.             LibraryProcedure Result, $(!DLLSQL), RegClose $(OpenServerKey)
  944.         endif
  945.         
  946.         LibraryProcedure Key, $(!DLLSQL), RegOpen "\\"$(!ComputerName),$(!RegSQLSetup)
  947.         ifstr(i) $(Key) != "KEY_ERROR"
  948.             LibraryProcedure !SQLPath, $(!DLLSQL), RegRead $(Key),$(!RegValSQLPath)
  949.             LibraryProcedure Result, $(!DLLSQL), RegClose $(Key)
  950.         endif
  951.         
  952.         shell "" DoExtractMasterAndErrorlog "\\"$(!ComputerName)
  953.         set !MasterDBPath = $($R2)
  954.         set !MasterDBFileName = $($R4)
  955.         set !DefMasterPath = $(!MasterDBPath)
  956.         set !DefMasterDB = $(!MasterDBFileName)
  957.         
  958.         ifstr(i) $(!RemoteSQLDrive) != ""
  959.             LibraryProcedure Temp, $(!DLLSQL), StrBeforeAndAfter $(!SQLPath),"AFTER",":"
  960.             set !SQLPath = $(!RemoteSQLDrive)$(Temp)
  961.         else
  962.             LibraryProcedure Before, $(!DLLSQL), StrBeforeAndAfter $(!SQLPath),"BEFORE","\"
  963.             set !LogicalSQLDrive = $(Before)
  964.         endif
  965.         ifstr(i) $(!RemoteDBDrive) != ""
  966.             LibraryProcedure Temp, $(!DLLSQL), StrBeforeAndAfter $(!MasterDBPath),"AFTER",":"
  967.             set !MasterDBPath = $(!RemoteDBDrive)$(Temp)
  968.         else
  969.             LibraryProcedure Before, $(!DLLSQL), StrBeforeAndAfter $(!MasterDBPath),"BEFORE","\"
  970.             set !LogicalDBDrive = $(Before)
  971.         endif
  972.         set !DefSQLPath = $(!SQLPath)
  973.     endif
  974.     
  975. prevDisplay =+
  976.     ifstr(i) $(!STF_OS) == "NT"
  977.         ifstr(i) $(!RegistryRebuild) == ""
  978.             ifstr(i) $(!Owner) == ""
  979.                 shell "" DoLicense
  980.                 ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  981.                     goto end_getprevii
  982.                 endif
  983.             else
  984.                 shell "" DoAlreadyInstalled
  985.                 ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  986.                     read-syms FailedUserSetupQuit$(!STF_LANGUAGE)
  987.                     goto end_getprevii
  988.                 endif
  989.             endif
  990.         endif
  991.         LibraryProcedure Result, $(!DLLSQL), DeleteSecurityAttribute $(!AdminACL)
  992.         LibraryProcedure !AdminACL, $(!DLLSQL), CreateSecurityAttribute "\\"$(!ComputerName),$(!AdministratorsGroup),"GENERIC_ALL","BUILTIN"
  993.         ifstr(i) $(!AdminACL) == "CANNOT_CREATE_ACL"
  994.             set !AdminACL = ""
  995.         endif
  996.     else
  997.         set !AdminACL = ""
  998.     endif
  999.     set Status = "STATUS_SUCCESSFUL"
  1000. end_getprevii =+
  1001.     Return $(Status)
  1002.         
  1003. [DoNewInstall]
  1004.     set Status = "STATUS_FAILED"
  1005.     ifstr(i) $(!LicenseSet) != "TRUE"
  1006.         shell "" DoLicense
  1007.         ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  1008.             goto end_new_inst2
  1009.         endif
  1010.     endif
  1011.     shell "" DoTestMachineName $(!ComputerName)
  1012.     ifstr(i) $($R0) == "STATUS_USERQUIT"
  1013.         set Status = "STATUS_USERQUIT"
  1014.         goto end_new_inst
  1015.     endif
  1016.     ifstr(i) $(!RegistryRebuild) == ""
  1017.         shell "" DoGetLicensingMode
  1018.     else
  1019.         ifint $(!LocalBuildNumber) > $(!LicenseMin)
  1020.             shell "" DoGetLicensingMode
  1021.         endif
  1022.     endif
  1023.     ifstr(i) $($R0) == "STATUS_USERQUIT"
  1024.         set Status = "STATUS_USERQUIT"
  1025.         goto end_new_inst
  1026.     else-ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  1027.         goto end_new_inst
  1028.     endif
  1029.     
  1030.     StartWait
  1031.     read-syms InstallError$(!STF_LANGUAGE)
  1032.     ifint $(!LogicalSystemMemory) < $(!MinSystemMemory)
  1033.         read-syms InsufficientMem$(!STF_LANGUAGE)
  1034.         LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)
  1035.         goto end_new_inst
  1036.     endif
  1037.     
  1038.     LibraryProcedure CNChk, $(!DLLSQL), StrBeforeAndAfter $(!ComputerName),"LASTBEFORE"," "
  1039.     ifstr(i) $(CNChk) != ""
  1040.         read-syms STR_SpacedComputerName
  1041.         LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)
  1042.         goto end_new_inst
  1043.     endif
  1044.     ifstr(i) $(!GrownPageFile) == ""
  1045.         LibraryProcedure Result, $(!DLLSQL), GrowPageFile "10000000"
  1046.         set !GrownPageFile = "1"
  1047.     endif
  1048.     
  1049.     ifstr(i) $(!RegistryRebuild) == ""
  1050.         shell "" StopService $(!SQLMonitorService)
  1051.         ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  1052.             goto end_new_inst
  1053.         endif
  1054.         shell "" StopService $(!SQLSchedulerService)
  1055.         ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  1056.             goto end_new_inst
  1057.         endif
  1058.         shell "" StopService $(!SQLOldSchedulerService)
  1059.         ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  1060.             goto end_new_inst
  1061.         endif
  1062.         shell "" StopService $(!SQLServerService)
  1063.         ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  1064.             goto end_new_inst
  1065.         endif
  1066.         shell "" StopService $(!SQLOldServerService)
  1067.         ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  1068.             goto end_new_inst
  1069.         endif
  1070.         
  1071.         LibraryProcedure !MSVCFileVersion, $(!DLLSQL), GetProductFileVersion $(!STF_CWDDIR)$(!MSVCModule)
  1072.         LibraryProcedure !MFCFileVersion, $(!DLLSQL), GetProductFileVersion $(!STF_CWDDIR)$(!MFCModule)
  1073.         LibraryProcedure !MSVC20FileVersion $(!DLLSQL), GetProductFileVersion $(!STF_CWDDIR)$(!MSVC20Module)
  1074.         LibraryProcedure !CTL3DFileVersion $(!DLLSQL), GetProductFileVersion $(!STF_CWDDIR)$(!CTL3DModule)
  1075.  
  1076.         StartWait
  1077.         set GetCost = "TRUE"
  1078.         install InstallBaseInstallFiles
  1079.         set GetCost = ""
  1080.         LibraryProcedure InstallationReqSpace, $(!DLLSQL), CheckStringFormat "FMT_SPACE","KILO",$(SpaceCost)
  1081.         
  1082.         
  1083.         set !AddlScripts = $(!DefScriptList)
  1084.         set !NetSelList        = {}
  1085.         set !CheckInstList = $(!CheckInstDefList)
  1086.         set !CheckInstRetList = $(!CheckInstDefRetList)
  1087.         set !CheckInstList = >( $(!CheckInstList), $(!SQLPubs))
  1088.         set !CheckInstRetList = >( $(!CheckInstRetList), $(!Pubs))
  1089.         set !CheckInstList = >( $(!CheckInstList), $(!SQLXPStar1))
  1090.         set !CheckInstList = >( $(!CheckInstList), $(!SQLXPStar2))
  1091.         set !CheckInstList = >( $(!CheckInstList), $(!SQLOle1))
  1092.         set !CheckInstRetList = >( $(!CheckInstRetList), $(!XpStarChk1))
  1093.         set !CheckInstRetList = >( $(!CheckInstRetList), $(!XpStarChk2))
  1094.         set !CheckInstRetList = >( $(!CheckInstRetList), $(!SqlOleChk1))
  1095.         set !CheckInstList = >( $(!CheckInstList), $(!SQLHelpSQL))
  1096.         set !CheckInstRetList = >( $(!CheckInstRetList), $(!RetHelpSQL))
  1097.         set !SortOrderSelList = $(!SortISOSelList)
  1098.         set !TheCharSet       = *( $(!CharSetSelList), 2 )
  1099.         LibraryProcedure Idx, $(!DLLSQL), IntMultiply $(!DefSortFileIndex),"3"
  1100.         set !TheSortConfigValue = *( $(!SortOrderSelList), $(Idx) )
  1101.         set-sub Idx = $(Idx),1
  1102.         set !TheSortFile = *( $(!SortOrderSelList), $(Idx) )
  1103.     endif
  1104.     set !ServerNMPipeName = $(!SvrPipe)
  1105.     shell "" DoNetDefaults
  1106.     EndWait
  1107.     
  1108. backToSQLPath =+
  1109.     shell "" DoGetSpaceSQLPath GetSpaceSQLPathDlg$(!STF_LANGUAGE),$(InstallationReqSpace),$(SpaceCost),"1","SPACE","",$(!LogicalSQLDrive)
  1110.     ifstr(i) $($R0) == "STATUS_BACK"
  1111.         set Status = "STATUS_BACK"
  1112.         goto end_new_inst
  1113.     else-ifstr(i) $($R0) == "STATUS_USERQUIT"
  1114.         set Status = "STATUS_USERQUIT"
  1115.         goto end_new_inst
  1116.     else-ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  1117.         goto end_new_inst
  1118.     endif
  1119.     set !SQLPath = $($R1)$($R2)
  1120.     set !DefSQLPath = $(!SQLPath)
  1121.     set !CreateSQLPath = $(!SQLPath)
  1122.     ifstr(i) $(!RemoteComputer) == ""
  1123.         set !LogicalSQLDrive = $($R1)
  1124.         set !LogicalDBDrive = $(!LogicalSQLDrive)
  1125.     else
  1126.         set !RemSQLPath = $(!LogicalSQLDrive)$($R2)
  1127.     endif
  1128.     set !DefMasterPath = $(!SQLPath)"\"$(!DataDir)"\"$(!DefMasterDB)
  1129. backToMasterPath =+
  1130.     shell "" DoGetSpaceMasterPath GetSpaceMasterPathDlg,$(InstallationReqSpace),$(SpaceCost),"1","SPACE","",$(!LogicalDBDrive)
  1131.     ifstr(i) $($R0) == "STATUS_BACK"
  1132.         goto backToSQLPath
  1133.     else-ifstr(i) $($R0) == "STATUS_USERQUIT"
  1134.         set Status = "STATUS_USERQUIT"
  1135.         goto end_new_inst
  1136.     else-ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  1137.         goto end_new_inst
  1138.     endif
  1139.     
  1140. backToSQLBooks =+
  1141.     ifstr(i) $(!SQLBooksInst) == "NO"
  1142.         goto backToNewOpts
  1143.     endif
  1144.     shell "" DoGetSQLBooksInstall
  1145.     ifstr(i) $($R0) == "STATUS_BACK"
  1146.         goto backToMasterPath
  1147.     else-ifstr(i) $($R0) == "STATUS_USERQUIT"
  1148.         set Status = "STATUS_USERQUIT"
  1149.         goto end_new_inst
  1150.     else-ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  1151.         goto end_new_inst
  1152.     endif
  1153.     
  1154. backToNewOpts =+
  1155.     shell "" DoNewOptions
  1156.     ifstr(i) $($R0) == "STATUS_BACK"
  1157.         ifstr(i) $(!SQLBooksInst) == "NO"
  1158.             goto backToMasterPath
  1159.         else
  1160.             goto backToSQLBooks
  1161.         endif
  1162.     else-ifstr(i) $($R0) == "STATUS_USERQUIT"
  1163.         set Status = "STATUS_USERQUIT"
  1164.         goto end_new_inst
  1165.     else-ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  1166.         goto end_new_inst
  1167.     endif
  1168.     ifstr(i) $(!RegistryRebuild) == ""
  1169.         shell "" DoGetUserID
  1170.         ifstr(i) $($R0) == "STATUS_BACK"
  1171.             goto backToNewOpts
  1172.         else-ifstr(i) $($R0) == "STATUS_USERQUIT"
  1173.             set Status = "STATUS_USERQUIT"
  1174.             goto end_new_inst
  1175.         else-ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  1176.             goto end_new_inst
  1177.         endif
  1178.     endif
  1179. skipuserid=+
  1180.     shell "" DoNetLibPrompts $(!NetLibList), "FALSE"
  1181.     ifstr(i) $($R0) == "STATUS_BACK"
  1182.         goto skipuserid
  1183.     else-ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  1184.         goto end_new_inst
  1185.     endif
  1186.     set NewNetLibs = $($R1)
  1187.     set NewNetAddrs = $($R2)
  1188.     
  1189.     ifstr(i) $(!RegistryRebuild) == ""
  1190.         read-syms MailManDlg$(!STF_LANGUAGE)
  1191.         LibraryProcedure DlgMailMan, $(!DLLSQL), BillBoard $(STF_HWND),$(DlgTemplate),$(!SQLDlgNames)
  1192.         
  1193.         read-syms ProgressCopyVars
  1194.         install InstallBaseInstallFiles
  1195.         ifstr(i) $(STF_INSTALL_OUTCOME) != "STF_SUCCESS"
  1196.             LibraryProcedure Result, $(!DLLSQL), CloseDialog $(DlgMailMan)
  1197.             read-syms FileCouldNotBeCopied$(!STF_LANGUAGE)
  1198.             LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)
  1199.             goto end_new_inst
  1200.         endif
  1201.         LibraryProcedure Result, $(!DLLSQL), CloseDialog $(DlgMailMan)
  1202.         
  1203.         ifstr(i) $(!RemoteComputer) == ""
  1204.             read-syms DLG_BillboardSearchRename
  1205.             LibraryProcedure DlgMailMan, $(!DLLSQL), BillBoard $(STF_HWND),$(DlgTemplate),$(!SQLDlgNames)
  1206.             LibraryProcedure Result, $(!DLLSQL), Sleepy "2"
  1207.             ForListDo $(!ClientDLLList)
  1208.                 LibraryProcedure Result, $(!DLLSQL), FindAndRenameVersionFile $(!SQLPath)"\"$(!Binaries)"\"$($)
  1209.                 ifstr(i) $(Result) != ""
  1210.                     set !OneOffFile = $(Result)
  1211.                     LibraryProcedure Result, $(!DLLSQL), CloseDialog $(DlgMailMan)
  1212.                     read-syms STR_DLLRenameError
  1213.                     LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)
  1214.                     goto end_new_inst
  1215.                 endif
  1216.             EndForListDo
  1217.             LibraryProcedure Result, $(!DLLSQL), CloseDialog $(DlgMailMan)
  1218.         endif
  1219.     endif
  1220.     ifstr(i) $(!RemoteComputer) == ""
  1221.         shell "" UpdateOleReg "", ""
  1222.     endif
  1223.     
  1224.     ifstr(i) $(!SQLBooksType) != "3"
  1225.         shell "" UpdateMSIN
  1226.     endif
  1227.     ifstr(i) $(!KeysDupped) == "TRUE"
  1228.         LibraryProcedure OpenServerKey, $(!DLLSQL), RegMakeKey "\\"$(!ComputerName),$(!RegSQLServer),$(!RegSQLServerSvr),$(!AdminACL)
  1229.         ifstr(i) $(OpenServerKey) != "KEY_ERROR"
  1230.             LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenServerKey),$(!RegValListenOn),$(!RegTypeMulti),$(!DefListenOn),""
  1231.             LibraryProcedure Result, $(!DLLSQL), RegClose $(OpenServerKey)
  1232.         endif
  1233.     endif
  1234.     
  1235.     ifstr(i) $(!RegistryRebuild) == ""
  1236.         shell "" DoReBuild "TRUE"
  1237.         ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  1238.             goto end_new_inst
  1239.         endif
  1240.     else
  1241.         shell "" RegWriteSerialNumberInfo
  1242.         ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  1243.             goto end_new_inst
  1244.         endif
  1245.         shell "" DoPerfmonNuke "\\"$(!ComputerName)
  1246.         shell "" UpdateSCM "TRUE"
  1247.     endif
  1248.     LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$(!ComputerName),"UNIDELETE",$(!RegLicInfoKey),$(!RegOldLicenseSubKey)
  1249.     shell "" UpdateRegistry $(NewNetLibs),$(NewNetAddrs),"TRUE"
  1250.     ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  1251.         goto end_new_inst
  1252.     endif
  1253.     
  1254.     ifstr(i) $(!RemoteComputer) == ""
  1255.         install CreateSQLProgmanItems
  1256.     endif
  1257.     
  1258.     ifstr(i) $(!RegistryRebuild) == ""
  1259.         ifstr(i) $(!ODBCInstall) == "YES"
  1260.             shell "" InstallODBC
  1261.             ifstr(i) $(!RISCInst) != "YES"
  1262.                 LibraryProcedure Result, $(!DLLSQL), WritePrivProfStr "ODBC 32 bit Data Sources","Local Server","SQL Server (32 bit)",$(!SystemDirectory)"\..\ODBC.INI"
  1263.                 LibraryProcedure Result, $(!DLLSQL), WritePrivProfStr "Local Server","Driver32",$(!SystemDirectory)"\SQLSRV32.DLL",$(!SystemDirectory)"\..\ODBC.INI"
  1264.                 LibraryProcedure ResultKey, $(!DLLSQL), RegMakeKey "\\"$(!ComputerName),"Software\Microsoft","Query","","HKEY_CURRENT_USER"
  1265.                 ifstr(i) $(ResultKey) != "KEY_ERROR"
  1266.                     LibraryProcedure Result, $(!DLLSQL), RegClose $(ResultKey)
  1267.                     LibraryProcedure ResultKey, $(!DLLSQL), RegMakeKey "\\"$(!ComputerName),"Software\Microsoft\Query","2.0","","HKEY_CURRENT_USER"
  1268.                     ifstr(i) $(ResultKey) != "KEY_ERROR"
  1269.                         LibraryProcedure Result, $(!DLLSQL), RegClose $(ResultKey)
  1270.                         LibraryProcedure ResultKey, $(!DLLSQL), RegMakeKey "\\"$(!ComputerName),"Software\Microsoft\Query\2.0","Data Sources","","HKEY_CURRENT_USER"
  1271.                         ifstr(i) $(ResultKey) != "KEY_ERROR"
  1272.                             set TempList = {}
  1273.                             LibraryProcedure TempList, $(!DLLSQL), RegEnumKeyValues "\\"$(!ComputerName),"Software\Microsoft\Query\2.0\Data Sources","VALUENAMES"
  1274.                             ifcontains(i) "Local Server" in $(TempList)
  1275.                                 set TempList = {}
  1276.                             else
  1277.                                 LibraryProcedure Result, $(!DLLSQL), RegSet $(ResultKey),"Local Server","REG_SZ","sa",""
  1278.                                 LibraryProcedure Result, $(!DLLSQL), RegClose $(ResultKey)
  1279.                             endif
  1280.                         endif
  1281.                     endif
  1282.                 endif
  1283.  
  1284.                 LibraryProcedure OpenSetupKey, $(!DLLSQL), RegMakeKey "\\"$(!ComputerName),"SOFTWARE","",""
  1285.                 ifstr(i) $(ResultKey) != "KEY_ERROR"
  1286.                     LibraryProcedure Result, $(!DLLSQL), RegClose $(ResultKey)
  1287.                     LibraryProcedure ResultKey, $(!DLLSQL), RegMakeKey "\\"$(!ComputerName),"SOFTWARE\ODBC","",""
  1288.                     ifstr(i) $(ResultKey) != "KEY_ERROR"
  1289.                         LibraryProcedure Result, $(!DLLSQL), RegClose $(ResultKey)
  1290.                         LibraryProcedure ResultKey, $(!DLLSQL), RegMakeKey "\\"$(!ComputerName),"SOFTWARE\ODBC\ODBC.INI","",""
  1291.                         ifstr(i) $(ResultKey) != "KEY_ERROR"
  1292.                             LibraryProcedure Result, $(!DLLSQL), RegClose $(ResultKey)
  1293.                             LibraryProcedure ResultKey, $(!DLLSQL), RegMakeKey "\\"$(!ComputerName),"SOFTWARE\ODBC\ODBC.INI\Local Server","",""
  1294.                             ifstr(i) $(ResultKey) != "KEY_ERROR"
  1295.                                 LibraryProcedure Result, $(!DLLSQL), RegSet $(ResultKey),"Description","REG_SZ","",""
  1296.                                 LibraryProcedure Result, $(!DLLSQL), RegSet $(ResultKey),"Driver","REG_SZ",$(!SystemDirectory)"\SQLSRV32.DLL",""
  1297.                                 LibraryProcedure Result, $(!DLLSQL), RegSet $(ResultKey),"OEMTOANSI","REG_SZ","Yes",""
  1298.                                 LibraryProcedure Result, $(!DLLSQL), RegSet $(ResultKey),"Server","REG_SZ","(local)",""
  1299.                                 LibraryProcedure Result, $(!DLLSQL), RegSet $(ResultKey),"Trusted_Connection","REG_SZ","",""
  1300.                                 LibraryProcedure Result, $(!DLLSQL), RegSet $(ResultKey),"UseProcForPrepare","REG_SZ","Yes",""
  1301.                                 LibraryProcedure Result, $(!DLLSQL), RegClose $(ResultKey)
  1302.                             endif
  1303.                             LibraryProcedure ResultKey, $(!DLLSQL), RegMakeKey "\\"$(!ComputerName),"SOFTWARE\ODBC\ODBC.INI\ODBC Data Sources","",""
  1304.                             ifstr(i) $(ResultKey) != "KEY_ERROR"
  1305.                                 LibraryProcedure Result, $(!DLLSQL), RegSet $(ResultKey),"Local Server","REG_SZ","SQL Server",""
  1306.                                 LibraryProcedure Result, $(!DLLSQL), RegClose $(ResultKey)
  1307.                             endif
  1308.                         endif
  1309.                     endif
  1310.                 endif
  1311.             endif
  1312.         endif
  1313.     endif
  1314.     
  1315.     ifstr(i) $(!RemoteComputer) != ""
  1316.         shell "" UpdateOleReg "", ""
  1317.     endif
  1318.     
  1319.     shell "" RegisterMSDTC
  1320.     
  1321.     set Status = "STATUS_SUCCESSFUL"
  1322.     
  1323.     end_new_inst = +
  1324.     
  1325.     StartWait
  1326.     
  1327.     ForListDo $(!DelDLLList)
  1328.         LibraryProcedure Result, $(!DLLSQL), Delnode "FILE_DELETE",$(!SystemDirectory)"\"$($)
  1329.     EndForListDo
  1330.     
  1331.     ifstr(i) $(!RemoteComputer) != ""
  1332.         LibraryProcedure Result, $(!DLLSQL), Delnode "FILE_DELETE",$(!SystemDirectory)"\"$(!DelODBCDLLList)
  1333.         LibraryProcedure Result, $(!DLLSQL), Delnode "TREE_DELETE",$(!SQLPath)"\"$(!SQLODBCDir)
  1334.     endif
  1335.     
  1336.     EndWait
  1337. end_new_inst2 =+
  1338.     Return $(Status)
  1339.         
  1340. [DoInstallUtils]
  1341.     set Status = "STATUS_FAILED"
  1342.     set DlgMailMan = ""
  1343.     set !UserType = "User"
  1344.     read-syms UtilInstallError$(!STF_LANGUAGE)
  1345.     ifstr(i) $(!STF_OS) == "NT"
  1346.         shell "" DoAdminCheck
  1347.         ifstr(i) $($R0) == "STATUS_SUCCESSFUL"
  1348.             set !UserType = "Admin"
  1349.         endif
  1350.     endif
  1351.     set !MsgText = ""
  1352. backToUtilPath =+
  1353.     shell "" DoGetUtilsAndPath
  1354.     ifstr(i) $($R0) == "STATUS_BACK"
  1355.         set Status = "STATUS_BACK"
  1356.         goto end_inst_utils
  1357.     else-ifstr(i) $($R0) == "STATUS_SUCCESSFUL"
  1358.         set !SQLPath = $($R1)$($R2)
  1359.         set !CreateSQLPath = $(!SQLPath)
  1360.         ifstr(i) $(!RemoteComputer) == ""
  1361.             set !LogicalSQLDrive = $($R1)
  1362.         endif
  1363.     else
  1364.         goto end_inst_utils
  1365.     endif
  1366.     
  1367.     ifstr(i) $(!SQLBooksInst) == "NO"
  1368.         goto noSQLBooks
  1369.     endif
  1370.     shell "" DoGetSQLBooksInstall
  1371.     ifstr(i) $($R0) == "STATUS_BACK"
  1372.         goto backToUtilPath
  1373.     else-ifstr(i) $($R0) == "STATUS_USERQUIT"
  1374.         set Status = "STATUS_USERQUIT"
  1375.         goto end_inst_utils
  1376.     else-ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  1377.         goto end_inst_utils
  1378.     endif
  1379. noSQLBooks =+
  1380.     read-syms MailManDlg$(!STF_LANGUAGE)
  1381.     LibraryProcedure DlgMailMan, $(!DLLSQL), BillBoard $(STF_HWND),$(DlgTemplate),$(!SQLDlgNames)
  1382.     
  1383.     ForListDo $(!ClientDLLList)
  1384.         LibraryProcedure Result, $(!DLLSQL), FindAndRenameVersionFile $(!SQLPath)"\"$(!Binaries)"\"$($)
  1385.     EndForListDo
  1386.     
  1387.     read-syms ProgressCopyVars
  1388.     install InstallUtilFiles
  1389.     ifstr(i) $(STF_INSTALL_OUTCOME) != "STF_SUCCESS"
  1390.         read-syms FileCouldNotBeCopied$(!STF_LANGUAGE)
  1391.         LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)
  1392.         goto end_inst_utils
  1393.     endif
  1394.     
  1395.         ProcessExecute Result,"WAIT",$(!SQLPath)"\"$(!Binaries)"\REGSVR32 /s "$(!SQLPath)"\"$(!Binaries)"\"$(!SQLOle32)
  1396.  
  1397.         ProcessExecute Result,"WAIT",$(!SQLPath)"\"$(!Binaries)"\REGSVR32 /s "$(!SQLPath)"\"$(!Binaries)"\"$(!ODSOle32)
  1398.         LibraryProcedure Result, $(!DLLSQL), Delnode "FILE_DELETE",$(!SQLPath)"\"$(!Binaries)"\REGSVR32.EXE"
  1399.     
  1400.     ifstr(i) $(!SQLBooksType) != "3"
  1401.         shell "" UpdateMSIN
  1402.     endif
  1403.     
  1404.     ifstr(i) $(!STF_OS) == "NT"
  1405.         set ConnectPath = "\\"$(!ComputerName)
  1406.     else
  1407.         set ConnectPath = ""
  1408.     endif
  1409.     
  1410.     ifstr(i) $(!UserType) == "Admin"
  1411.         shell "" RegWriteSystemPaths $(ConnectPath),$(!RegSystemPaths),""
  1412.         ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  1413.             goto end_inst_utils
  1414.         endif
  1415.     else
  1416.         shell "" RegWriteSystemPaths $(ConnectPath),$(!RegUserPaths),"1"
  1417.         ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  1418.             goto end_inst_utils
  1419.         endif
  1420.     endif
  1421.     
  1422.     shell "" RegWriteDBLibDefaults $(ConnectPath)
  1423.     ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  1424.         goto end_inst_utils
  1425.     endif
  1426.     
  1427.     shell "" RegWriteClientKeys $(ConnectPath)
  1428.     ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  1429.         goto end_inst_utils
  1430.     endif
  1431.     
  1432.     ifstr(i) $(!RemoteComputer) == ""
  1433.         install CreateUtilProgmanItems
  1434.     endif
  1435.     
  1436.     ifstr(i) $(!ODBCInstall) == "YES"
  1437.         shell "" InstallODBC
  1438.     endif
  1439.     
  1440.     set Status = "STATUS_SUCCESSFUL"
  1441.     end_inst_utils = +
  1442.     ifstr(i) $(DlgMailMan) != ""
  1443.         LibraryProcedure Result, $(!DLLSQL), CloseDialog $(DlgMailMan)
  1444.     endif
  1445.     EndWait
  1446.     Return $(Status)
  1447.     
  1448. [DoUpgrade]
  1449.     set Status = "STATUS_FAILED"
  1450.     set BillyBoard = ""
  1451.     set !UpgErrors = ""
  1452.     set !WasSingleMode = ""
  1453.     set Pre42 = "YES"
  1454.     ifstr(i) $(!LicenseSet) != "TRUE"
  1455.         shell "" DoLicense
  1456.         ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  1457.             goto finish_upgrade
  1458.         endif
  1459.     endif
  1460.     shell "" DoTestMachineName $(!ComputerName)
  1461.     ifstr(i) $($R0) == "STATUS_USERQUIT"
  1462.         set Status = "STATUS_USERQUIT"
  1463.         goto finish_upgrade
  1464.     endif
  1465.     ifstr(i) $(!RegistryRebuild) == ""
  1466.         shell "" DoGetLicensingMode
  1467.     else
  1468.         ifint $(!LocalBuildNumber) > $(!LicenseMin)
  1469.             shell "" DoGetLicensingMode
  1470.         endif
  1471.     endif
  1472.     ifstr(i) $($R0) == "STATUS_USERQUIT"
  1473.         set Status = "STATUS_USERQUIT"
  1474.         goto finish_upgrade
  1475.     else-ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  1476.         goto finish_upgrade
  1477.     endif
  1478.     shell "" DoLicense60Nuke
  1479.     shell "" DoNetDefaults
  1480.     LibraryProcedure OpenServerKey, $(!DLLSQL), RegOpen "\\"$(!ComputerName),$(!RegSQLServer)"\"$(!RegSQLServerSvr)
  1481.     ifstr(i) $(OpenServerKey) != "KEY_ERROR"
  1482.         LibraryProcedure !ListenOn, $(!DLLSQL), RegRead $(OpenServerKey),$(!RegValListenOn)
  1483.         ForListDo $(!ListenOn)
  1484.             LibraryProcedure Before, $(!DLLSQL), StrBeforeAndAfter $($),"BEFORE",","
  1485.             ifstr(i) $(Before) == $(!NetLibTCPIP)
  1486.                 set !NetLibList = >( $(!NetLibList), $(!NetLibTCPIP))
  1487.             endif
  1488.         EndForListDo
  1489.     endif
  1490.     LibraryProcedure Result, $(!DLLSQL), RegClose $(OpenServerKey)
  1491.     
  1492.     set !ServerNMPipeName = $(!SvrPipe)
  1493.     read-syms UpgradeError$(!STF_LANGUAGE)
  1494.     
  1495. backToWarning1 =+
  1496.     read-syms UpgradeWarning1$(!STF_LANGUAGE)
  1497.     shell "" UpgradeQ
  1498.     ifstr(i) $($R0) == "STATUS_BACK"
  1499.         set Status = "STATUS_BACK"
  1500.         goto finish_upgrade
  1501.     else-ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  1502.         goto finish_upgrade
  1503.     endif
  1504.     
  1505.     LibraryProcedure CNChk, $(!DLLSQL), StrBeforeAndAfter $(!ComputerName),"LASTBEFORE"," "
  1506.     ifstr(i) $(CNChk) != ""
  1507.         read-syms STR_SpacedComputerName
  1508.         LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)
  1509.         goto finish_upgrade
  1510.     endif
  1511.     
  1512. backToGetSQLPath =+
  1513.     shell "" DoGetSpaceSQLPath GetUpgradeSQLPathDlg$(!STF_LANGUAGE),$(InstallationReqSpace),$(SpaceCost),"1","","",$(!LogicalSQLDrive)
  1514.     ifstr(i) $($R0) == "STATUS_BACK"
  1515.         set Status = "STATUS_BACK"
  1516.         goto backToWarning1
  1517.     else-ifstr(i) $($R0) == "STATUS_USERQUIT"
  1518.         set Status = "STATUS_USERQUIT"
  1519.         goto finish_upgrade
  1520.     else-ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  1521.         goto finish_upgrade
  1522.     endif
  1523.     set !SQLPath = $($R1)$($R2)
  1524.     set !DefSQLPath = $(!SQLPath)
  1525.     set !CreateSQLPath = $(!SQLPath)
  1526.     ifstr(i) $(!RemoteComputer) == ""
  1527.         set !LogicalSQLDrive = $($R1)
  1528.         ifstr(i) $(!Owner) == ""
  1529.             set !LogicalDBDrive = $(!LogicalSQLDrive)
  1530.         endif
  1531.     else
  1532.         set !RemSQLPath = $(!LogicalSQLDrive)$($R2)
  1533.     endif
  1534.     
  1535.     ifstr(i) $(!MasterDBFileName) == ""
  1536.         set !DefMasterPath = $(!SQLPath)"\"$(!DataDir)"\"$(!MasterDB)
  1537.     else
  1538.         set !DefMasterPath = $(!MasterDBPath)"\"$(!MasterDBFileName)
  1539.     endif
  1540. backToGetMaster =+
  1541.     shell "" DoGetSpaceSQLPath GetUpgradeSQLMasterPathDlg,$(InstallationReqSpace),$(SpaceCost),"1","","MASTERFORMAT_MUSTEXIST",$(!LogicalDBDrive),"MASTERPATH"
  1542.     ifstr(i) $($R0) == "STATUS_BACK"
  1543.         set Status = "STATUS_BACK"
  1544.         goto backToGetSQLPath
  1545.     else-ifstr(i) $($R0) == "STATUS_USERQUIT"
  1546.         set Status = "STATUS_USERQUIT"
  1547.         goto finish_upgrade
  1548.     else-ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  1549.         goto finish_upgrade
  1550.     endif
  1551.     set !MasterDBFileName = $($R3)
  1552.     set !MasterDBPath = $($R1)$($R2)
  1553.     set !DefMasterPath = $(!MasterDBPath)"\"$(!MasterDBFileName)
  1554.     ifstr(i) $(!RemoteComputer) == ""
  1555.         set !LogicalDBDrive = $($R1)
  1556.     endif
  1557.     
  1558. backToSQLBooksUp =+
  1559.     shell "" DoGetSQLBooksInstall
  1560.     ifstr(i) $($R0) == "STATUS_BACK"
  1561.         goto backToGetMaster
  1562.     else-ifstr(i) $($R0) == "STATUS_USERQUIT"
  1563.         set Status = "STATUS_USERQUIT"
  1564.         goto finish_upgrade
  1565.     else-ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  1566.         goto finish_upgrade
  1567.     endif
  1568.     
  1569.     
  1570. backtoIntegratedSec =+
  1571.     ifstr(i) $(!IntegratedSecurity) == ""
  1572.         shell "" DoGetSAPassword
  1573.         ifstr(i) $($R0) == "STATUS_BACK"
  1574.             goto backToSQLBooksUp
  1575.         else-ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  1576.             goto finish_upgrade
  1577.         endif
  1578.     endif
  1579. backtouserid =+
  1580.     ifstr(i) $(!RegistryRebuild) == ""
  1581.         shell "" DoGetUserID
  1582.         ifstr(i) $($R1) == "TRUE"
  1583.             ifstr(i) $(!RemoteComputer) == ""
  1584.                 set NewSQLPath = $(!SQLPath)
  1585.             else
  1586.                 LibraryProcedure Temp, $(!DLLSQL), StrBeforeAndAfter $(!SQLPath),"AFTER",":"
  1587.                 LibraryProcedure NewSQLPath, $(!DLLSQL), AppendToString $(!LogicalSQLDrive),$(Temp)
  1588.             endif
  1589.             LibraryProcedure Result, $(!DLLSQL), DoServiceOp "\\"$(!ComputerName),"SERVICE_CREATE",$(!SQLServerService) ,$(NewSQLPath)"\"$(!Binaries)"\"$(!SQLServer),"","","",$(StartType),"1"
  1590.         endif
  1591.         ifstr(i) $($R0) == "STATUS_BACK"
  1592.             goto backtoIntegratedSec
  1593.         else-ifstr(i) $($R0) == "STATUS_USERQUIT"
  1594.             set Status = "STATUS_USERQUIT"
  1595.             goto finish_upgrade
  1596.         else-ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  1597.             goto finish_upgrade
  1598.         endif
  1599.     endif
  1600. skipsecuserid=+
  1601.     read-syms UpgradeWarning2$(!STF_LANGUAGE)
  1602.     shell "" UpgradeQ
  1603.     ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  1604.         goto finish_upgrade
  1605.     endif
  1606.     
  1607.     
  1608.     shell "" StopService $(!SQLMonitorService)
  1609.     ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  1610.         goto finish_upgrade
  1611.     endif
  1612.     shell "" StopService $(!SQLSchedulerService)
  1613.     ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  1614.         goto finish_upgrade
  1615.     endif
  1616.     shell "" StopService $(!SQLOldSchedulerService)
  1617.     ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  1618.         goto finish_upgrade
  1619.     endif
  1620.     shell "" StopService $(!SQLServerService)
  1621.     ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  1622.         goto finish_upgrade
  1623.     endif
  1624.     shell "" StopService $(!SQLOldServerService)
  1625.     ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  1626.         goto finish_upgrade
  1627.     endif
  1628.     
  1629.     
  1630.     read-syms MailManDlg$(!STF_LANGUAGE)
  1631.     LibraryProcedure DlgMailMan, $(!DLLSQL), BillBoard $(STF_HWND),$(DlgTemplate),$(!SQLDlgNames)
  1632.     
  1633.     LibraryProcedure !MSVCFileVersion, $(!DLLSQL), GetProductFileVersion $(!STF_CWDDIR)$(!MSVCModule)
  1634.     LibraryProcedure !MFCFileVersion, $(!DLLSQL), GetProductFileVersion $(!STF_CWDDIR)$(!MFCModule)
  1635.     
  1636.     read-syms ProgressCopyVars
  1637.     install InstallBaseInstallFiles
  1638.     ifstr(i) $(STF_INSTALL_OUTCOME) != "STF_SUCCESS"
  1639.         LibraryProcedure Result, $(!DLLSQL), CloseDialog $(DlgMailMan)
  1640.         read-syms FileCouldNotBeCopied$(!STF_LANGUAGE)
  1641.         LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)
  1642.         goto finish_upgrade
  1643.     endif
  1644.     LibraryProcedure Result, $(!DLLSQL), CloseDialog $(DlgMailMan)
  1645.     
  1646.     read-syms DLG_BillboardSearchRename
  1647.     LibraryProcedure BillyBoard, $(!DLLSQL), BillBoard $(STF_HWND),$(DlgTemplate),$(!SQLDlgNames)
  1648.     LibraryProcedure Result, $(!DLLSQL), Sleepy "2"
  1649.     
  1650.     ifstr(i) $(!RemoteComputer) == ""
  1651.         ForListDo $(!ClientDLLList)
  1652.             LibraryProcedure Result, $(!DLLSQL), FindAndRenameVersionFile $(!SQLPath)"\"$(!Binaries)"\"$($)
  1653.             ifstr(i) $(Result) != ""
  1654.                 set !OneOffFile = $(Result)
  1655.                 read-syms STR_DLLRenameError
  1656.                 LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)
  1657.                 goto finish_upgrade
  1658.             endif
  1659.         EndForListDo
  1660.     endif
  1661.     
  1662.     ifstr(i) $(!RemoteComputer) == ""
  1663.         shell "" UpdateOleReg "", $(BillyBoard)
  1664.     endif
  1665.     
  1666.     ifstr(i) $(!SQLBooksType) != "3"
  1667.         shell "" UpdateMSIN
  1668.     endif
  1669.     
  1670.     
  1671.     read-syms STR_BillboardPrepUpgrade
  1672.     LibraryProcedure Result, $(!DLLSQL), UpdateBillboard $(BillyBoard),$(!BillName)
  1673.     
  1674.     ifstr(i) $(!Registration) == ""
  1675.         shell "" UpdateSCM "TRUE"
  1676.         ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  1677.             read-syms SCMError$(!STF_LANGUAGE)
  1678.             LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)
  1679.             LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$($R1)
  1680.             goto finish_upgrade
  1681.         endif
  1682.     else
  1683.         set CompVal = ""
  1684.         LibraryProcedure CompVal $(!DLLSQL), CompareVersions, $(!ProductVersion), $(!CurInstalledVer)
  1685.         ifstr(i) $(CompVal) == ">"
  1686.             shell "" UpdateSCM "TRUE"
  1687.         else-ifstr(i) $(!RegistryRebuild) != ""
  1688.             shell "" UpdateSCM "TRUE"
  1689.         else
  1690.             shell "" UpdateSCM "FALSE"
  1691.             ifstr(i) $(createSvc) == "TRUE"
  1692.                 ifstr(i) $(!RemoteComputer) == ""
  1693.                     set NewSQLPath = $(!SQLPath)
  1694.                 else
  1695.                     LibraryProcedure Temp, $(!DLLSQL), StrBeforeAndAfter $(!SQLPath),"AFTER",":"
  1696.                     LibraryProcedure NewSQLPath, $(!DLLSQL), AppendToString $(!LogicalSQLDrive),$(Temp)
  1697.                 endif
  1698.                 LibraryProcedure Result, $(!DLLSQL), DoServiceOp "\\"$(!ComputerName),"SERVICE_CREATE",$(!SQLServerService) ,$(NewSQLPath)"\"$(!Binaries)"\"$(!SQLServer),"","","",$(StartType),"1"
  1699.             endif
  1700.         endif
  1701.     endif
  1702.     
  1703.     shell "" UpdateMSIN
  1704.     
  1705.     shell "" RegWriteSerialNumberInfo
  1706.     ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  1707.         goto finish_upgrade
  1708.     endif
  1709.     LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$(!ComputerName),"UNIDELETE",$(!RegLicInfoKey),$(!RegOldLicenseSubKey)
  1710.     ifstr(i) $(!SQL95Keys) != "TRUE"
  1711.         shell "" UpdateSCM "TRUE"
  1712.     endif
  1713. endif
  1714.     LibraryProcedure OpenServerKey, $(!DLLSQL), RegMakeKey "\\"$(!ComputerName),$(!RegSQLServer),$(!RegSQLServerSvr),$(!AdminACL)
  1715.     ifstr(i) $(OpenServerKey) != "KEY_ERROR"
  1716.         LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenServerKey),$(!RegValListenOn),$(!RegTypeMulti),$(!DefListenOn),""
  1717.         LibraryProcedure Result, $(!DLLSQL), RegClose $(OpenServerKey)
  1718.     endif
  1719.  
  1720.     LibraryProcedure TmpParamList, $(!DLLSQL), RegEnumKeyValues "\\"$(!ComputerName),$(!RegSQLServerServer)"\"$(!RegSQLSvrParam),"VALUEDATA"
  1721.     QueryListSize NumArgs $(TmpParamList)
  1722.     LibraryProcedure !OpenParamKey, $(!DLLSQL), RegMakeKey "\\"$(!ComputerName),$(!RegSQLServerServer),$(!RegSQLSvrParam),$(!AdminACL)
  1723.     LibraryProcedure Result, $(!DLLSQL), RegSet $(!OpenParamKey),$(!RegValParameter)$(NumArgs),$(!RegTypeString),$(!TraceSQLKeyDB),""
  1724.     set !RegValSQL95KeyDB = $(!RegValParameter)$(NumArgs)
  1725.     LibraryProcedure Result, $(!DLLSQL), RegClose $(!OpenParamKey)
  1726.  
  1727.     LibraryProcedure OpenSetupKey, $(!DLLSQL), RegMakeKey "\\"$(!ComputerName),$(!RegSQLSetup),"",$(!AdminACL)
  1728.     ifstr(i) $(OpenSetupKey) != "KEY_ERROR"
  1729.         LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenSetupKey),$(!RegValSetupState),$(!RegTypeString),$(!RegValUpgrading),""
  1730.         LibraryProcedure Result, $(!DLLSQL), RegClose $(OpenSetupKey)
  1731.     endif
  1732.     
  1733.     LibraryProcedure Result, $(!DLLSQL), Sleepy "5"
  1734.     
  1735.     shell "" StartService $(!SQLServerService)
  1736.     ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  1737.         goto finish_upgrade
  1738.     endif
  1739.  
  1740.     set Upg95Errors = ""
  1741.     LibraryProcedure Upg95Errors,$(!DLLSQL),CheckUpgrade,$(!ComputerName),$(!SALogin),$(!SAPassword),$(!SQLPath)"\"$(!InstallDir)"\"$(!UpgradeOut)
  1742.     
  1743.     LibraryProcedure Result, $(!DLLSQL), SQLLogin "0","4",$(!ServerName),$(!SALogin),$(!SAPassword)
  1744.     ifstr(i) $(Result) == "NO_SERVER"
  1745.         read-syms NoLoginToSQLServer$(!STF_LANGUAGE)
  1746.         LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)
  1747.         goto finish_upgrade
  1748.     endif
  1749.     
  1750.     ifstr(i) $(Upg95Errors) != ""
  1751.         set !AddlText = $(Upg95Errors)
  1752.         read-syms CheckUpgradeDlg$(!STF_LANGUAGE)
  1753.         LibraryProcedure !AddlText, $(!DLLSQL), AppendToString $(!AddlText),$(!LF)$(!LF)
  1754.         read-syms ChkUpgRepLoc$(!STF_LANGUAGE)
  1755.         LibraryProcedure !AddlText, $(!DLLSQL), AppendToString $(!AddlText),$(!Addl95Text)
  1756.         LibraryProcedure !AddlText, $(!DLLSQL), AppendToString $(!AddlText),$(!SQLPath)"\"$(!InstallDir)"\"$(!UpgradeOut)$(!LF)$(!LF)
  1757.         set Status = "STATUS_FAILED"
  1758.         shell "" DispCheckUpgrade
  1759.         goto checkupgnoerror
  1760.     endif
  1761.     
  1762.     shell "" DoUpgradeChecks
  1763.     set DBOperatingSys = $($R2)
  1764.     ifstr(i) $($R0) == "STATUS_OKFAILED"
  1765.         set Pre42 = "NO"
  1766.         goto upgrade_scripts
  1767.     else-ifstr(i) $($R0) == "STATUS_FAILED"
  1768.         read-syms SQLExecError$(!STF_LANGUAGE)
  1769.         LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)$($R1)
  1770.         goto finish_upgrade
  1771.     endif
  1772.     
  1773.     ifstr(i) $(!UpgErrors) != ""
  1774.         read-syms CannotUpgrade$(!STF_LANGUAGE)
  1775.         LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!UpgErrors)
  1776.         goto finish_upgrade
  1777.     endif
  1778.     
  1779. checkupgnoerror=+
  1780.     LibraryProcedure Result, $(!DLLSQL), SQLExecute $(!SQLUpgObjects)
  1781.     ifstr(i) $(Result) == "BAD_SQL_EXEC"
  1782.         read-syms SQLExecError$(!STF_LANGUAGE)
  1783.         LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)" #U7"$(!LF)
  1784.         LibraryProcedure !AddlText, $(!DLLSQL), SQLGetErrorMsg
  1785.         LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)
  1786.         goto finish_upgrade
  1787.     endif
  1788.     
  1789.     LibraryProcedure Result, $(!DLLSQL), SQLExecute $(!SQLUpgConfigMem)
  1790.     ifstr(i) $(Result) == "BAD_SQL_EXEC"
  1791.         read-syms SQLExecError$(!STF_LANGUAGE)
  1792.         LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)" #U8"$(!LF)
  1793.         LibraryProcedure !AddlText, $(!DLLSQL), SQLGetErrorMsg
  1794.         LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)
  1795.         goto finish_upgrade
  1796.     endif
  1797.     
  1798.     LibraryProcedure Result, $(!DLLSQL), SQLLogout
  1799.     
  1800. upgrade_scripts =+
  1801.     
  1802.     read-syms BillboardUpgrading$(!STF_LANGUAGE)
  1803.     LibraryProcedure Result, $(!DLLSQL), UpdateBillboard $(BillyBoard),$(!BillName)
  1804.     
  1805.     set TmpParamList = {}
  1806.     LibraryProcedure TmpParamList, $(!DLLSQL), RegEnumKeyValues "\\"$(!ComputerName),$(!RegSQLServerServer)"\"$(!RegSQLSvrParam),"VALUEDATA"
  1807.     ifcontains(i) $(!SingleUserMode) in $(TmpParamList)
  1808.         set !WasSingleMode = "YES"
  1809.     else
  1810.         set !WasSingleMode = "NO"
  1811.     endif
  1812.     
  1813.     ifstr(i) $(!WasSingleMode) == "NO"
  1814.         QueryListSize NumArgs $(TmpParamList)
  1815.         LibraryProcedure !OpenParamKey, $(!DLLSQL), RegMakeKey "\\"$(!ComputerName),$(!RegSQLServerServer),$(!RegSQLSvrParam),$(!AdminACL)
  1816.         LibraryProcedure Result, $(!DLLSQL), RegSet $(!OpenParamKey),$(!RegValParameter)$(NumArgs),$(!RegTypeString),$(!SingleUserMode),""
  1817.         set !RegValSingleUserArg = $(!RegValParameter)$(NumArgs)
  1818.         LibraryProcedure Result, $(!DLLSQL), RegClose $(!OpenParamKey)
  1819.     endif
  1820.  
  1821.     set TmpParamList = {}
  1822.     LibraryProcedure TmpParamList, $(!DLLSQL), RegEnumKeyValues "\\"$(!ComputerName),$(!RegSQLServerServer)"\"$(!RegSQLSvrParam),"VALUEDATA"
  1823.     QueryListSize NumArgs $(TmpParamList)
  1824.     LibraryProcedure !OpenParamKey, $(!DLLSQL), RegMakeKey "\\"$(!ComputerName),$(!RegSQLServerServer),$(!RegSQLSvrParam),$(!AdminACL)
  1825.     LibraryProcedure Result, $(!DLLSQL), RegSet $(!OpenParamKey),$(!RegValParameter)$(NumArgs),$(!RegTypeString),$(!TFlagBypassSSP),""
  1826.     set !RegValBypassSSPArg = $(!RegValParameter)$(NumArgs)
  1827.     LibraryProcedure Result, $(!DLLSQL), RegClose $(!OpenParamKey)
  1828.  
  1829.     shell "" RegWriteANSIOEM
  1830.     ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  1831.         goto finish_upgrade
  1832.     endif
  1833.  
  1834.     read-syms BillboardUpgrading$(!STF_LANGUAGE)
  1835.     LibraryProcedure Result, $(!DLLSQL), UpdateBillboard $(BillyBoard),$(!BillName)
  1836.     
  1837.     LibraryProcedure Result, $(!DLLSQL), SQLLogout
  1838.  
  1839.     shell "" StopService $(!SQLServerService)
  1840.     
  1841.     
  1842.     shell "" StartService $(!SQLServerService)
  1843.     ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  1844.         goto finish_upgrade
  1845.     endif
  1846.         
  1847.         LibraryProcedure Result, $(!DLLSQL), SQLLogin "0","4",$(!ServerName),$(!SALogin),$(!SAPassword)
  1848.         ifstr(i) $(Result) == "NO_SERVER"
  1849.                read-syms NoLoginToSQLServer$(!STF_LANGUAGE)
  1850.                LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)
  1851.                goto finish_upgrade
  1852.         endif
  1853.         
  1854.         set !CheckInstList = {}
  1855.         ForListDo $(!CheckInstDefList)
  1856.             set !CheckInstList = >( $(!CheckInstList), $($))
  1857.         EndForListDo
  1858.         set TheUpgScripts = $(!UpgScriptsNT42)
  1859.         set TheReqMem = $(!UpgMemNT42)
  1860.         ifstr(i) $(Pre42) == "NO"
  1861.             shell "" CheckMasterSpace
  1862.             ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  1863.                 LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),"#1"
  1864.                 goto finish_upgrade
  1865.             endif
  1866.             ifint $($R1) < $(TheReqMem)
  1867.                 ifstr(i) $(!UpgOverride) != ""
  1868.                     shell "" Popup "4.2 Upgrade Space insufficient. Requires "$(TheReqMem)", has "$($R1)
  1869.                 else
  1870.                     LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!UpgErrorMastSpace)
  1871.                     goto finish_upgrade
  1872.                 endif
  1873.             endif
  1874.         endif
  1875.         
  1876.         shell "" ExecNReturnSQLCmd $(!SQLGetMemory),"INTBIND"
  1877.         ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  1878.             set ErrorNumber = " #U1"
  1879.             goto finish_upgrade
  1880.         endif
  1881.         set Mem = $($R1)
  1882.         LibraryProcedure Result, $(!DLLSQL), SQLLogout
  1883.         set !CheckInstRetList = $(!CheckInstDefRetList)
  1884.         
  1885.         shell "" CreateConfig $(Mem)
  1886.         ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  1887.             goto finish_upgrade
  1888.         endif
  1889.         
  1890.         shell "" CheckInstalledScripts $(TheUpgScripts)
  1891.         set TheUpgScripts = $($R1)
  1892.         ifstr(i) $(!BMsdb) == "YES"
  1893.             shell "" BuildMSDB
  1894.         endif
  1895.  
  1896.         ForListDo $(TheUpgScripts)
  1897.             StartWait
  1898.             ifstr(i) $(!KeysDupped) == "FALSE"
  1899.                 ifstr(i) $($) == $(!InstAdmin)
  1900.                     goto nextScript
  1901.                 else-ifstr(i) $($) == $(!InstOM)
  1902.                     goto nextScript
  1903.                 endif
  1904.             endif
  1905.             LibraryProcedure Before, $(!DLLSQL), StrBeforeAndAfter $($),"BEFORE","."
  1906.             ProcessExecute Result,"WAIT",$(!SQLPath)"\"$(!Binaries)"\"$(!ISQL)" /n /S"$(!ServerName)" /Usa /i"$(!SQLPath)"\"$(!InstallDir)"\"$($)" /o"$(!SQLPath)"\"$(!InstallDir)"\"$(Before)".OUT /P"$(!SAPassword)
  1907.             EndWait
  1908.             ifstr(i) $(Before) != "EARLY1"
  1909.                 ifstr(i) $(Result) == "PROCESS_ERROR"
  1910.                     read-syms ProcessExecError$(!STF_LANGUAGE)
  1911.                     LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!ISQL)" "$(!AddlText)
  1912.                     goto finish_upgrade
  1913.                 endif
  1914.             endif
  1915. nextScript =+
  1916.         EndForListDo
  1917.         
  1918.         shell "" CheckInstallSuccess "TRUE"
  1919.         ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  1920.             goto finish_upgrade
  1921.         endif
  1922.         
  1923.         shell "" InstallWEBProc
  1924.         ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  1925.             goto finish_upgrade
  1926.         endif
  1927.  
  1928.         ifstr(i) $(!Locale) != ""
  1929.             shell "" DoLangInst $(!Locale),$(!SAPassword),"CHECKED"
  1930.             ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  1931.                 goto finish_upgrade
  1932.             endif
  1933.         endif
  1934.         
  1935.         shell "" StopService $(!SQLServerService)
  1936.         
  1937.         shell "" UpdateRegistry $(!NetLibList),$(!NetAddresses),"FALSE"
  1938.         ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  1939.             goto finish_upgrade
  1940.         endif
  1941.  
  1942.         ifstr(i) $(!RemoteComputer) == ""
  1943.             ifstr(i) $(!MarketBetaUpgrade) == "TRUE"
  1944.                 set !ProgramTitle =  $(!SQLBetaProgmanGrpName)
  1945.                 install NukeSQLProgmanItems
  1946.                 LibraryProcedure Result, $(!DLLSQL), Sleepy "3"
  1947.             endif
  1948.             set !SQL60ProgramTitle = $(!SQL60ProgmanGrpName)
  1949.             install NukeSQL60ProgmanItems
  1950.             install CreateSQLProgmanItems
  1951.         endif
  1952.  
  1953.         ifstr(i) $(!KeysDupped) == "TRUE"
  1954.             set RemoveOld = "TRUE"
  1955.         else-ifstr(i) $(RemoteKeysDupped) == "TRUE"
  1956.             set RemoveOld = "TRUE"
  1957.         endif
  1958.         ifstr(i) $(RemoveOld) == "TRUE"
  1959.             read-syms BillboardRemoveOld$(!STF_LANGUAGE)
  1960.             LibraryProcedure Result, $(!DLLSQL), UpdateBillboard $(BillyBoard),$(!BillName)
  1961.             LibraryProcedure Temp, $(!DLLSQL), StrBeforeAndAfter $(!SQLPath),"AFTER",":"
  1962.             LibraryProcedure NewSQLPath, $(!DLLSQL), AppendToString $(!LogicalSQLDrive),$(Temp)
  1963.             ForListDo $(!DrpBinnFiles)
  1964.                 LibraryProcedure Result, $(!DLLSQL), Delnode "FILE_DELETE",$(NewSQLPath)"\"$(!Binaries)"\"$($)
  1965.             EndForListDo
  1966.             ForListDo $(!DrpDLLFiles)
  1967.                 LibraryProcedure Result, $(!DLLSQL), Delnode "FILE_DELETE",$(NewSQLPath)"\"$(!Binaries)"\"$($)
  1968.             EndForListDo
  1969.             ForListDo $(!DrpInsFiles)
  1970.                 LibraryProcedure Result, $(!DLLSQL), Delnode "FILE_DELETE",$(NewSQLPath)"\"$(!InstallDir)"\"$($)
  1971.             EndForListDo
  1972.         endif
  1973.  
  1974.         LibraryProcedure Result, $(!DLLSQL), Delnode "TREE_DELETE", $(!SQLPath)"\"$(!DLLs)
  1975.         
  1976.         ifstr(i) $(!RemoteComputer) != ""
  1977.             shell "" UpdateOleReg "", $(BillyBoard)
  1978.         endif
  1979.         
  1980.         shell "" RegisterMSDTC
  1981.  
  1982.         ifstr(i) $(!RegistryRebuild) == ""
  1983.             ifstr(i) $(!ODBCInstall) == "YES"
  1984.                 ifstr(i) $(BillyBoard) != ""
  1985.                     LibraryProcedure Result, $(!DLLSQL), CloseDialog $(BillyBoard)
  1986.                 endif
  1987.                 set BillyBoard = ""
  1988.                 shell "" InstallODBC
  1989.                 ifstr(i) $(!RISCInst) != "YES"
  1990.                     LibraryProcedure Result, $(!DLLSQL), WritePrivProfStr "ODBC 32 bit Data Sources","Local Server","SQL Server (32 bit)",$(!SystemDirectory)"\..\ODBC.INI"
  1991.                     LibraryProcedure Result, $(!DLLSQL), WritePrivProfStr "Local Server","Driver32",$(!SystemDirectory)"\SQLSRV32.DLL",$(!SystemDirectory)"\..\ODBC.INI"
  1992.                     LibraryProcedure ResultKey, $(!DLLSQL), RegMakeKey "\\"$(!ComputerName),"Software\Microsoft","Query","","HKEY_CURRENT_USER"
  1993.                     ifstr(i) $(ResultKey) != "KEY_ERROR"
  1994.                         LibraryProcedure Result, $(!DLLSQL), RegClose $(ResultKey)
  1995.                         LibraryProcedure ResultKey, $(!DLLSQL), RegMakeKey "\\"$(!ComputerName),"Software\Microsoft\Query","2.0","","HKEY_CURRENT_USER"
  1996.                         ifstr(i) $(ResultKey) != "KEY_ERROR"
  1997.                             LibraryProcedure Result, $(!DLLSQL), RegClose $(ResultKey)
  1998.                             LibraryProcedure ResultKey, $(!DLLSQL), RegMakeKey "\\"$(!ComputerName),"Software\Microsoft\Query\2.0","Data Sources","","HKEY_CURRENT_USER"
  1999.                             ifstr(i) $(ResultKey) != "KEY_ERROR"
  2000.                                 set TempList = {}
  2001.                                 LibraryProcedure TempList, $(!DLLSQL), RegEnumKeyValues "\\"$(!ComputerName),"Software\Microsoft\Query\2.0\Data Sources","VALUENAMES"
  2002.                                 ifcontains(i) "Local Server" in $(TempList)
  2003.                                     set TempList = {}
  2004.                                 else
  2005.                                     LibraryProcedure Result, $(!DLLSQL), RegSet $(ResultKey),"Local Server","REG_SZ","sa",""
  2006.                                     LibraryProcedure Result, $(!DLLSQL), RegClose $(ResultKey)
  2007.                                 endif
  2008.                             endif
  2009.                         endif
  2010.                     endif
  2011.                 endif
  2012.             endif
  2013.         endif
  2014.  
  2015.         ifstr(i) $(!KeysDupped) == "TRUE"
  2016.             ifstr(i) $(!InstallType) == "2"
  2017.                 install RemoveOldSQLGroup
  2018.             endif
  2019.         endif
  2020.         
  2021.         set Status = "STATUS_SUCCESSFUL"
  2022. finish_upgrade =+
  2023.         LibraryProcedure Result, $(!DLLSQL), SQLLogout
  2024.         ifstr(i) $(!RegValSQL95KeyDB) != ""
  2025.             LibraryProcedure OpenParamKey, $(!DLLSQL), RegMakeKey "\\"$(!ComputerName),$(!RegSQLServer)"\"$(!RegSQLServerSvr),$(!RegSQLSvrParam),$(!AdminACL)
  2026.             LibraryProcedure Result, $(!DLLSQL), RegDelValue $(OpenParamKey),$(!RegValSQL95KeyDB)
  2027.             LibraryProcedure Result, $(!DLLSQL), RegClose $(OpenParamKey)
  2028.         endif
  2029.         ifstr(i) $(!WasSingleMode) == "NO"
  2030.             ifstr(i) $(!RegValSingleUserArg) != ""
  2031.                 LibraryProcedure !OpenParamKey, $(!DLLSQL), RegMakeKey "\\"$(!ComputerName),$(!RegSQLServerServer),$(!RegSQLSvrParam),$(!AdminACL)
  2032.                 LibraryProcedure Result, $(!DLLSQL), RegDelValue $(!OpenParamKey),$(!RegValSingleUserArg)
  2033.                 LibraryProcedure Result, $(!DLLSQL), RegClose $(!OpenParamKey)
  2034.             endif
  2035.             set !WasSingleMode = ""
  2036.         endif
  2037.  
  2038.         ifstr(i) $(!RegValBypassSSPArg) != ""
  2039.             LibraryProcedure OpenParamKey, $(!DLLSQL), RegMakeKey "\\"$(!ComputerName),$(!RegSQLServer)"\"$(!RegSQLServerSvr),$(!RegSQLSvrParam),$(!AdminACL)
  2040.             LibraryProcedure Result, $(!DLLSQL), RegDelValue $(OpenParamKey),$(!RegValBypassSSPArg)
  2041.             LibraryProcedure Result, $(!DLLSQL), RegClose $(OpenParamKey)
  2042.         endif
  2043.  
  2044.         shell "" StopService $(!SQLServerService)
  2045.         ForListDo $(!DelDLLList)
  2046.             LibraryProcedure Result, $(!DLLSQL), Delnode "FILE_DELETE",$(!SystemDirectory)"\"$($)
  2047.         EndForListDo
  2048.         ifstr(i) $(!RemoteComputer) != ""
  2049.             LibraryProcedure Result, $(!DLLSQL), Delnode "FILE_DELETE",$(!SystemDirectory)"\"$(!DelODBCDLLList)
  2050.             LibraryProcedure Result, $(!DLLSQL), Delnode "TREE_DELETE",$(!SQLPath)"\"$(!SQLODBCDir)
  2051.         endif
  2052.         ifstr(i) $(BillyBoard) != ""
  2053.             LibraryProcedure Result, $(!DLLSQL), CloseDialog $(BillyBoard)
  2054.         endif
  2055.         Return $(Status)
  2056.                 
  2057. [UpgradeQ]
  2058.         LibraryProcedure DlgUpg, $(!DLLSQL), SQLDlgDisplay $(STF_HWND),$(!DlgTemplate),"",$(!SQLDlgNames),"MODAL",""
  2059. upgradeQ =+
  2060.         LibraryProcedure DLGEVENT, $(!DLLSQL), WaitEvent
  2061.         ifstr(i) $(DLGEVENT) == "EXIT"
  2062.             shell "" QueryUserQuit $(!STF_LANGUAGE)
  2063.             ifstr(i) $($R1) == "OK"
  2064.                 set Status = "STATUS_USERQUIT"
  2065.                 goto end_upgrade
  2066.             else
  2067.                 goto upgradeQ
  2068.             endif
  2069.         else-ifstr(i) $(DLGEVENT) == "CONTINUE"
  2070.             set Status = "STATUS_SUCCESSFUL"
  2071.         else-ifstr(i) $(DLGEVENT) == "BACK"
  2072.             set Status = "STATUS_BACK"
  2073.         endif
  2074. end_upgrade =+
  2075.         LibraryProcedure Result, $(!DLLSQL), CloseDialog $(DlgUpg)
  2076.         Return $(Status)
  2077.                 
  2078. [DoUpgradeChecks]
  2079.         set Status = "STATUS_FAILED"
  2080.         set DBOperatingSys = ""
  2081.         set !UpgErrors = ""
  2082.         
  2083.         shell "" ExecNReturnSQLCmd $(!SQLGetMasterOS),"STRINGBIND"
  2084.         ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  2085.             set ErrorNumber = " #U0"
  2086.             goto finish_upgrade_check
  2087.         endif
  2088.         LibraryProcedure DBOperatingSys, $(!DLLSQL), StrBeforeAndAfter $($R1),"BEFORE"," "
  2089.         
  2090.         shell "" ExecNReturnSQLCmd $(!SQLCheckVersion),"INTBIND"
  2091.         ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  2092.             set ErrorNumber = " #U1"
  2093.             goto finish_upgrade_check
  2094.         endif
  2095.         ifstr(i) $($R1) != ""
  2096.             ifstr(i) $($R1) != "0"
  2097.                 set Status = STATUS_OKFAILED
  2098.                 goto finish_upgrade_check
  2099.             endif
  2100.         endif
  2101.         
  2102.         shell "" CheckMasterSpace
  2103.         ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  2104.             set ErrorNumber = " #U3"
  2105.             goto finish_upgrade_check
  2106.         endif
  2107.         
  2108.         shell "" ExecNReturnSQLCmd $(!SQLGetConfOpen),"INTBIND"
  2109.         ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  2110.             set ErrorNumber = " #U5"
  2111.             goto finish_upgrade_check
  2112.         endif
  2113.         set NumDBs = $($R1)
  2114.         shell "" ExecNReturnSQLCmd $(!SQLGetNumDBs),"INTBIND"
  2115.         ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  2116.             set ErrorNumber = " #U6"
  2117.             goto finish_upgrade_check
  2118.         endif
  2119.         ifint $($R1) > $(NumDBs)
  2120.             LibraryProcedure !UpgErrors, $(!DLLSQL), AppendToString $(!UpgErrors),$(!UpgErrorNumDBs)
  2121.         endif
  2122.     endif
  2123.     set Status = "STATUS_SUCCESSFUL"
  2124. finish_upgrade_check =+
  2125.     Return $(Status) $(ErrorNumber) $(DBOperatingSys)
  2126.         
  2127. [CheckMasterSpace]
  2128.     set Status = "STATUS_FAILED"
  2129.     set Size = ""
  2130.     LibraryProcedure Result, $(!DLLSQL), SQLAddtoCmdBuff $(!SQLCheckMasterSpace)
  2131.     LibraryProcedure Result, $(!DLLSQL), SQLExecuteCmdBuff
  2132.     ifstr(i) $(Result) == "BAD_SQL_EXEC"
  2133.         read-syms SQLExecError$(!STF_LANGUAGE)
  2134.         LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)$(!LF)
  2135.         LibraryProcedure !AddlText, $(!DLLSQL), SQLGetErrorMsg
  2136.         LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)$(!LF)
  2137.         goto end_getmasterspace
  2138.     endif
  2139.     LibraryProcedure Result, $(!DLLSQL), SQLGetNextResultSet
  2140.     LibraryProcedure Result, $(!DLLSQL), SQLNextRow $(!PurgeRows)
  2141.     LibraryProcedure Result, $(!DLLSQL), SQLGetNextResultSet
  2142.     LibraryProcedure Result, $(!DLLSQL), SQLNextRow $(!PurgeRows)
  2143.     LibraryProcedure Result, $(!DLLSQL), SQLGetNextResultSet
  2144.     ifstr(i) $(Result) != "BAD_RESULTS"
  2145.         LibraryProcedure Result, $(!DLLSQL), SQLBindColumn "INTBIND", "1"
  2146.         LibraryProcedure Result, $(!DLLSQL), SQLNextRow $(!OneNextRow)
  2147.         LibraryProcedure Size, $(!DLLSQL), SQLGetBindingData "1"
  2148.         LibraryProcedure Result, $(!DLLSQL), SQLNextRow $(!PurgeRows)
  2149.     endif
  2150.     set Status = "STATUS_SUCCESSFUL"
  2151. end_getmasterspace=+
  2152.     Return $(Status) $(Size)
  2153.         
  2154. [DoInstallLang]
  2155.     set Status = "STATUS_FAILED"
  2156.     set BillyBoard = ""
  2157.     read-syms LangError$(!STF_LANGUAGE)
  2158. backToGetLangInfo =+
  2159.     shell "" DoGetLangInfo
  2160.     ifstr(i) $($R0) == "STATUS_BACK"
  2161.         set Status = "STATUS_BACK"
  2162.         goto end_instlang
  2163.     else-ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  2164.         goto end_instlang
  2165.     endif
  2166.     
  2167.     set LanguageName = $($R1)
  2168.     set SAPassword = $($R2)
  2169.     set DefaultLanguage = $($R3)
  2170.     
  2171.     set !DestPath = $(!SQLPath)"\"$(!LocalesDir)"\"$(LanguageName)
  2172.     read-syms GetLangFileDlg$(!STF_LANGUAGE)
  2173.     set !SQLDLGPath = $(!DefSQLDLGPath)
  2174.     shell "" DoGetPath
  2175.     ifstr(i) $($R0) == "STATUS_BACK"
  2176.         goto backToGetLangInfo
  2177.     else-ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  2178.         goto end_instlang
  2179.     endif
  2180.     set !SrcPath = $(!PathOut)
  2181.     
  2182.     read-syms ProgressCopyVars
  2183.     install CopyLangFiles
  2184.     ifstr(i) $(STF_INSTALL_OUTCOME) != "STF_SUCCESS"
  2185.         read-syms FileCouldNotBeCopied$(!STF_LANGUAGE)
  2186.         LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)
  2187.         goto end_instlang
  2188.     endif
  2189.     
  2190.     StartWait
  2191.     read-syms InstLangingDlg$(!STF_LANGUAGE)
  2192.     LibraryProcedure BillyBoard, $(!DLLSQL), BillBoard $(STF_HWND),"",$(!SQLDlgNames)
  2193.     
  2194.     shell "" StartService $(!SQLServerService)
  2195.     ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  2196.         goto end_instlang
  2197.     endif
  2198.     
  2199.     shell "" DoLangInst $(LanguageName),$(SAPassword),$(DefaultLanguage)
  2200.     ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  2201.         goto end_instlang
  2202.     endif
  2203.     
  2204.     set Status = "STATUS_SUCCESSFUL"
  2205. end_instlang =+
  2206.     ifstr(i) $(BillyBoard) != ""
  2207.         LibraryProcedure Result, $(!DLLSQL), CloseDialog $(BillyBoard)
  2208.     endif
  2209.     EndWait
  2210.     Return $(Status)
  2211.         
  2212. [DoLangInst]
  2213.     set Status = "STATUS_FAILED"
  2214.     StartWait
  2215.     ProcessExecute Result,"WAIT",$(!SQLPath)"\"$(!Binaries)"\"$(!LangInst)" /S"$(!ServerName)" /P"$($1)" /o"$(!SQLPath)"\"$(!InstallDir)"\"$(!LangInstOut)" /L"$(!SQLPath)" "$($0)
  2216.     ifstr(i) $(Result) == "PROCESS_ERROR"
  2217.         read-syms ProcessExecError$(!STF_LANGUAGE)
  2218.         LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!LangInst)" "$(!AddlText)
  2219.         goto end_instlang
  2220.     else-ifstr(i) $(Result) != "0"
  2221.         read-syms ProcessRetError$(!STF_LANGUAGE)
  2222.         LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!LangInst)" "$(!AddlText)" "$(Result)
  2223.         goto end_instlang
  2224.     endif
  2225.     
  2226.     ifstr(i) $($2) == "CHECKED"
  2227.         LibraryProcedure Result, $(!DLLSQL), SQLLogin "0","4",$(!ServerName),$(!SALogin),$($1)
  2228.         ifstr(i) $(Result) != "NO_SERVER"
  2229.             LibraryProcedure Result, $(!DLLSQL), SQLExecute $(!SQLSetLang)
  2230.             ifstr(i) $(Result) == "BAD_SQL_EXEC"
  2231.                 read-syms SQLExecError$(!STF_LANGUAGE)
  2232.                 LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)" UST #1"$(!LF)
  2233.                 LibraryProcedure !AddlText, $(!DLLSQL), SQLGetErrorMsg
  2234.                 LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)
  2235.                 goto end_instlang
  2236.             endif
  2237.             LibraryProcedure Result, $(!DLLSQL), SQLExecute $(!SQLReconfigure)
  2238.             ifstr(i) $(Result) == "BAD_SQL_EXEC"
  2239.                 read-syms SQLExecError$(!STF_LANGUAGE)
  2240.                 LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)" UST #2"$(!LF)
  2241.                 LibraryProcedure !AddlText, $(!DLLSQL), SQLGetErrorMsg
  2242.                 LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)
  2243.                 goto end_instlang
  2244.             endif
  2245.         else
  2246.             read-syms NoLoginToSQLServer$(!STF_LANGUAGE)
  2247.             LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)
  2248.         endif
  2249.     endif
  2250.     set Status = "STATUS_SUCCESSFUL"
  2251. end_instlang =+
  2252.     LibraryProcedure Result, $(!DLLSQL), SQLLogout
  2253.     EndWait
  2254.     Return $(Status)
  2255.         
  2256. [DoGetServerParameters]
  2257.     set Status = "STATUS_FAILED"
  2258.     LibraryProcedure ParamList, $(!DLLSQL), RegEnumKeyValues "\\"$(!ComputerName),$(!RegSQLServerServer)"\"$(!RegSQLSvrParam),"VALUEDATA"
  2259.     read-syms ServerParamsDlg$(!STF_LANGUAGE)
  2260.     LibraryProcedure DlgParams, $(!DLLSQL), SQLDlgDisplay $(STF_HWND),$(DlgTemplate),"",$(!SQLDlgNames),"1",$(ParamList)
  2261.     ifstr(i) $(ParamList) != "KEY_ERROR"
  2262.         LibraryProcedure CurSel, $(!DLLSQL), DlgSetCmbCurSel $(DlgParams),"LISTBOX1","-1"
  2263.     endif
  2264. lang_info =+
  2265.     LibraryProcedure DLGEVENT, $(!DLLSQL), WaitEvent
  2266.     ifstr(i) $(DLGEVENT) == "EXIT"
  2267.         set Status = "STATUS_USERQUIT"
  2268.         goto end_langinfo
  2269.     else-ifstr(i) $(DLGEVENT) == "DLGBUTTON1"
  2270.         LibraryProcedure CurSel, $(!DLLSQL), DlgGetCmbCurSel $(DlgParams),"LISTBOX1"
  2271.         LibraryProcedure Param, $(!DLLSQL), DlgGetEditText $(DlgParams),"EDIT1"
  2272.         ifstr(i) $(Param) != ""
  2273.             LibraryProcedure Result, $(!DLLSQL), DlgAddCmbEntry $(DlgParams),"LISTBOX1",$(Param)
  2274.             LibraryProcedure Result, $(!DLLSQL), DlgSetEditText $(DlgParams),"EDIT1",""
  2275.             ifstr(i) $(CurSel) == "-1"
  2276.                 LibraryProcedure CurSel, $(!DLLSQL), DlgSetCmbCurSel $(DlgParams),"LISTBOX1","0"
  2277.             endif
  2278.         endif
  2279.         goto lang_info
  2280.     else-ifstr(i) $(DLGEVENT) == "DLGBUTTON2"
  2281.         LibraryProcedure CurSel, $(!DLLSQL), DlgGetCmbCurSel $(DlgParams),"LISTBOX1"
  2282.         LibraryProcedure Result, $(!DLLSQL), DlgDeleteCmbEntry $(DlgParams),"LISTBOX1",$(CurSel)
  2283.         ifint $(CurSel) > "1"
  2284.             set-sub CurSel = $(CurSel),1
  2285.         else
  2286.             set CurSel = 0
  2287.         endif
  2288.         LibraryProcedure CurSel, $(!DLLSQL), DlgSetCmbCurSel $(DlgParams),"LISTBOX1",$(CurSel)
  2289.         LibraryProcedure Result, $(!DLLSQL), DlgSetEditText $(DlgParams),"EDIT1",""
  2290.         goto lang_info
  2291.     else-ifstr(i) $(DLGEVENT) == "LISTBOX1"
  2292.         LibraryProcedure CurSel, $(!DLLSQL), DlgGetCmbCurSel $(DlgParams),"LISTBOX1"
  2293.         LibraryProcedure ListItem, $(!DLLSQL), DlgGetCmbCurText $(DlgParams),"LISTBOX1",$(CurSel)
  2294.         LibraryProcedure Result, $(!DLLSQL), DlgSetEditText $(DlgParams),"EDIT1",$(ListItem)
  2295.         goto lang_info
  2296.     else-ifstr(i) $(DLGEVENT) == "CONTINUE"
  2297.         StartWait
  2298.         LibraryProcedure NumParams, $(!DLLSQL), DlgCmbCount $(DlgParams),"LISTBOX1"
  2299.         set Params = {}
  2300.         set CurParam = 0
  2301. param_loop =+
  2302.         ifint $(CurParam) < $(NumParams)
  2303.             LibraryProcedure ListItem, $(!DLLSQL), DlgGetCmbCurText $(DlgParams),"LISTBOX1",$(CurParam)
  2304.             set Params = >( $(Params), $(ListItem))
  2305.             set-add CurParam = $(CurParam),1
  2306.             goto param_loop
  2307.         endif
  2308.         LibraryProcedure Param, $(!DLLSQL), DlgGetEditText $(DlgParams),"EDIT1"
  2309.         ifstr(i) $(Param) != ""
  2310.             set Params = >( $(Params), $(Param))
  2311.             set-add CurParam = $(CurParam),1
  2312.         endif
  2313.         LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$(!ComputerName),"UNIDELETE",$(!RegSQLServerServer),$(!RegSQLSvrParam)
  2314.         LibraryProcedure OpenParamKey, $(!DLLSQL), RegMakeKey "\\"$(!ComputerName),$(!RegSQLServerServer),$(!RegSQLSvrParam),$(!AdminACL)
  2315.         ifstr(i) $(OpenParamKey) == "KEY_ERROR"
  2316.             read-syms ErrorUpdatingRegistry$(!STF_LANGUAGE)
  2317.             LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)
  2318.             goto end_langinfo
  2319.         else
  2320.             ForListDo $(Params)
  2321.                 set-sub Count = $(#),1
  2322.                 LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenParamKey),$(!RegValParameter)$(Count),$(!RegTypeString),$($),""
  2323.             EndForListDo
  2324.         endif
  2325.         LibraryProcedure Result, $(!DLLSQL), RegClose $(OpenParamKey)
  2326.         set Status = "STATUS_SUCCESSFUL"
  2327.     else-ifstr(i) $(DLGEVENT) == "BACK"
  2328.         set Status = "STATUS_BACK"
  2329.         goto end_langinfo
  2330.     endif
  2331.     set Status = "STATUS_SUCCESSFUL"
  2332. end_langinfo =+
  2333.     EndWait
  2334.     LibraryProcedure Result, $(!DLLSQL), CloseDialog $(DlgParams)
  2335.     Return $(Status)
  2336.         
  2337. [DoTapeSupport]
  2338.     set Mins = ""
  2339.     set Status = "STATUS_FAILED"
  2340.     StartWait
  2341.     LibraryProcedure Mins, $(!DLLSQL), RegRead $($0),$(!RegValTapeWait)
  2342.     ifstr(i) $(Mins) == "KEY_ERROR"
  2343.         set !DefRadio = "1"
  2344.     else-ifstr(i) $(Mins) == "0"
  2345.         set !DefRadio = "2"
  2346.     else-ifstr(i) $(Mins) == "-1"
  2347.         set !DefRadio = "1"
  2348.     else
  2349.         set !DefRadio = "3"
  2350.     endif
  2351.     read-syms TapeTimeDlg$(!STF_LANGUAGE)
  2352.     LibraryProcedure DlgTape, $(!DLLSQL), SQLDlgDisplay $(STF_HWND),$(DlgTemplate),"",$(!SQLDlgNames),"MODAL",""
  2353.     ifstr(i) $(!DefRadio) == "3"
  2354.         LibraryProcedure Result, $(!DLLSQL), DlgSetEditText $(DlgTape),"EDIT1",$(Mins)
  2355.     endif
  2356. tape_sup =+
  2357.     ifstr(i) $(!DefRadio) == "3"
  2358.         LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(DlgTape),"TEXT1","TRUE"
  2359.         LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(DlgTape),"EDIT1","TRUE"
  2360.     else
  2361.         LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(DlgTape),"TEXT1","FALSE"
  2362.         LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(DlgTape),"EDIT1","FALSE"
  2363.     endif
  2364.     EndWait
  2365.     LibraryProcedure DLGEVENT, $(!DLLSQL), WaitEvent
  2366.     ifstr(i) $(DLGEVENT) == "EXIT"
  2367.         set Status = "STATUS_USERQUIT"
  2368.         goto end_tape_sup
  2369.     else-ifstr(i) $(DLGEVENT) == "DLGBUTTON1"
  2370.         set !DefRadio = "1"
  2371.         goto tape_sup
  2372.     else-ifstr(i) $(DLGEVENT) == "DLGBUTTON2"
  2373.         set !DefRadio = "2"
  2374.         goto tape_sup
  2375.     else-ifstr(i) $(DLGEVENT) == "DLGBUTTON3"
  2376.         set !DefRadio = "3"
  2377.         goto tape_sup
  2378.     else-ifstr(i) $(DLGEVENT) == "CONTINUE"
  2379.         ifstr(i) $(!DefRadio) == "1"
  2380.             set Mins = "-1"
  2381.         else-ifstr(i) $(!DefRadio) == "2"
  2382.             set Mins = "0"
  2383.         else
  2384.             LibraryProcedure Mins, $(!DLLSQL), DlgGetEditText $(DlgTape),"EDIT1"
  2385.             ifstr(i) $(Mins) == ""
  2386.                 goto tape_sup
  2387.             endif
  2388.         endif
  2389.         LibraryProcedure Result, $(!DLLSQL), RegSet $($0),$(!RegValTapeWait),$(!RegTypeDWord),$(Mins),""
  2390.     endif
  2391.     set Status = "STATUS_SUCCESSFUL"
  2392. end_tape_sup =+
  2393.     EndWait
  2394.     LibraryProcedure Result, $(!DLLSQL), CloseDialog $(DlgTape)
  2395.     Return $(Status)
  2396.         
  2397. [DoServerOptions]
  2398.     set Status = "STATUS_FAILED"
  2399.     read-syms ServerOptsError$(!STF_LANGUAGE)
  2400.     read-syms ServerOptsDlg$(!STF_LANGUAGE)
  2401.     
  2402.     LibraryProcedure DlgOpts, $(!DLLSQL), SQLDlgDisplay $(STF_HWND),$(DlgTemplate),"",$(!SQLDlgNames),"MODAL",""
  2403.     set NumCPUs = "2"
  2404.     ifstr(i) $(!RemoteComputer) == ""
  2405.         LibraryProcedure NumCPUs, $(!DLLSQL), GetNumProcessors
  2406.         ifint $(NumCPUs) < "2"
  2407.             LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(DlgOpts),"UNIBUTTON8","FALSE"
  2408.         endif
  2409.     endif
  2410.     
  2411.     shell "" DoParseServerInfo $(DlgOpts),"FALSE"
  2412.     set OpenSetupKey = $($R1)
  2413.     set OpenSvcKey = $($R2)
  2414.     set SQLPerf = $($R3)
  2415.     set ELogEntry = $($R4)
  2416.     set EMDBEntry = $($R5)
  2417.     set ParamCount = $($R6)
  2418.     set OpenMonSvcKey = $($R7)
  2419.     set OpenServerKey = $($R8)
  2420.     set OpenPerfKey = $($R9)
  2421.     LibraryProcedure NTELogInitial, $(!DLLSQL), IsDlgBtnChecked $(DlgOpts),"UNIBUTTON4"
  2422.     LibraryProcedure MailInitial, $(!DLLSQL), IsDlgBtnChecked $(DlgOpts),"UNIBUTTON2"
  2423.     LibraryProcedure SNMPInitial, $(!DLLSQL), IsDlgBtnChecked $(DlgOpts), "UNIBUTTON10"
  2424.  
  2425. serveropts =+
  2426.     LibraryProcedure DLGEVENT, $(!DLLSQL), WaitEvent
  2427.     ifstr(i) $(DLGEVENT) == "EXIT"
  2428.         shell "" QueryUserQuit $(!STF_LANGUAGE)
  2429.         ifstr(i) $($R1) == "OK"
  2430.             set Status = "STATUS_USERQUIT"
  2431.             goto end_serveropts
  2432.         else
  2433.             goto serveropts
  2434.         endif
  2435.     else-ifstr(i) $(DLGEVENT) == "BACK"
  2436.         set Status = "STATUS_BACK"
  2437.         goto end_serveropts
  2438.     else-ifstr(i) $(DLGEVENT) == "DLGBUTTON1"
  2439.         shell "" DoGetServerParameters
  2440.         ifstr(i) $($R0) == "STATUS_FAILED"
  2441.             goto end_serveropts
  2442.         else-ifstr(i) $($R0) == "STATUS_SUCCESSFUL"
  2443.             shell "" DoParseServerInfo $(DlgOpts),"TRUE"
  2444.         endif
  2445.         goto serveropts
  2446.     else-ifstr(i) $(DLGEVENT) == "DLGBUTTON2"
  2447.         shell "" DoTapeSupport $(OpenServerKey)
  2448.         ifstr(i) $($R0) == "STATUS_FAILED"
  2449.             goto end_serveropts
  2450.         endif
  2451.         goto serveropts
  2452.     else-ifstr(i) $(DLGEVENT) == "DLGBUTTON3"
  2453.         LibraryProcedure DoSQLCntrs, $(!DLLSQL), IsDlgBtnChecked $(DlgOpts),"DLGBUTTON3"
  2454.         ifstr(i) $(DoSQLCntrs) == "CHECKED"
  2455.             LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(DlgOpts),"UNIBUTTON6","TRUE"
  2456.             LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(DlgOpts),"UNIBUTTON7","TRUE"
  2457.         else
  2458.             LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(DlgOpts),"UNIBUTTON6","FALSE"
  2459.             LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(DlgOpts),"UNIBUTTON7","FALSE"
  2460.         endif
  2461.         goto serveropts
  2462.     else-ifstr(i) $(DLGEVENT) == "DLGBUTTON4"
  2463.         LibraryProcedure Result, $(!DLLSQL), IsDlgBtnChecked $(DlgOpts),"DLGBUTTON4"
  2464.         ifstr(i) $(Result) != "CHECKED"
  2465.             LibraryProcedure Result, $(!DLLSQL), DlgCheckButton $(DlgOpts),"DLGBUTTON4","FALSE"
  2466.         endif
  2467.         goto serveropts
  2468.     else-ifstr(i) $(DLGEVENT) == "DLGBUTTON5"
  2469.         LibraryProcedure Result, $(!DLLSQL), IsDlgBtnChecked $(DlgOpts),"DLGBUTTON5"
  2470.         ifstr(i) $(Result) == "CHECKED"
  2471.             LibraryProcedure Result, $(!DLLSQL), DlgCheckButton $(DlgOpts),"DLGBUTTON5","TRUE"
  2472.         endif
  2473.         goto serveropts
  2474.     else-ifstr(i) $(DLGEVENT) == "DLGBUTTON6"
  2475.         shell "" DoGetMailInfo
  2476.         ifstr(i) $($R0) == "STATUS_USERQUIT"
  2477.             goto end_serveropts
  2478.         endif
  2479.         goto serveropts
  2480.     else-ifstr(i) $(DLGEVENT) == "CONTINUE"
  2481.         StartWait
  2482.         
  2483.         LibraryProcedure !SQLPath, $(!DLLSQL), DlgGetEditText $(DlgOpts),"EDIT1"
  2484.         ifstr(i) $(!SQLPath) == ""
  2485.             read-syms NoServerPath$(!STF_LANGUAGE)
  2486.             shell "" MessageError
  2487.             goto serveropts
  2488.         endif
  2489.         
  2490.         LibraryProcedure !PathOut, $(!DLLSQL), DlgGetEditText $(DlgOpts),"EDIT2"
  2491.         LibraryProcedure Before, $(!DLLSQL), StrBeforeAndAfter $(!PathOut),"LASTBEFORE","\"
  2492.         ifstr(i) $(Before) == ""
  2493.             read-syms NoMasterPath$(!STF_LANGUAGE)
  2494.             shell "" MessageError
  2495.             goto serveropts
  2496.         endif
  2497.         LibraryProcedure After, $(!DLLSQL), StrBeforeAndAfter $(!PathOut),"LASTAFTER","\"
  2498.         LibraryProcedure PathAfter, $(!DLLSQL), StrBeforeAndAfter $(After),"LASTAFTER","."
  2499.         ifstr(i) $(PathAfter) == ""
  2500.             read-syms DBNoDat$(!STF_LANGUAGE)
  2501.             shell "" MessageError
  2502.             goto serveropts
  2503.         endif
  2504.         set !MasterDBFileName = $(After)
  2505.         set !MasterDBPath = $(Before)
  2506.         
  2507.         ifstr(i) $(NTELogInitial) == "CHECKED"
  2508.             LibraryProcedure Result, $(!DLLSQL), IsDlgBtnChecked $(DlgOpts),"UNIBUTTON4"
  2509.             ifstr(i) $(Result) != "CHECKED"
  2510.                 read-syms DeleteEventLog$(!STF_LANGUAGE)
  2511.                 read-syms YesNoDlg$(!STF_LANGUAGE)
  2512.                 ui start $(DlgTemplate)
  2513.                 ifstr(i) $(DLGEVENT) == "NO"
  2514.                     LibraryProcedure Result, $(!DLLSQL), DlgCheckButton $(DlgOpts),"UNIBUTTON4", "TRUE"
  2515.                     goto serveropts
  2516.                 endif
  2517.             endif
  2518.         endif
  2519.         
  2520.         LibraryProcedure MailInfo, $(!DLLSQL), IsDlgBtnChecked $(DlgOpts),"UNIBUTTON2"
  2521.         ifstr(i) $(MailInitial) != "CHECKED"
  2522.             ifstr(i) $(MailInfo) == "CHECKED"
  2523.                 shell "" DoGetMailInfo
  2524.                 ifstr(i) $($R0) == "STATUS_BACK"
  2525.                     goto serveropts
  2526.                 endif
  2527.                 ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  2528.                     goto end_serveropts
  2529.                 endif
  2530.             endif
  2531.         endif
  2532.         
  2533.         
  2534.         LibraryProcedure ELogPath, $(!DLLSQL), DlgGetEditText $(DlgOpts),"EDIT3"
  2535.         LibraryProcedure SvcStart, $(!DLLSQL), IsDlgBtnChecked $(DlgOpts),"DLGBUTTON4"
  2536.         LibraryProcedure MonSvcStart, $(!DLLSQL), IsDlgBtnChecked $(DlgOpts),"DLGBUTTON5"
  2537.         LibraryProcedure NTELog, $(!DLLSQL), IsDlgBtnChecked $(DlgOpts),"UNIBUTTON4"
  2538.         LibraryProcedure DoSQLCntrs, $(!DLLSQL), IsDlgBtnChecked $(DlgOpts),"DLGBUTTON3"
  2539.         LibraryProcedure PerfSync, $(!DLLSQL), IsDlgBtnChecked $(DlgOpts),"UNIBUTTON6"
  2540.         LibraryProcedure ImpClient, $(!DLLSQL), IsDlgBtnChecked $(DlgOpts),"UNIBUTTON9"
  2541.         LibraryProcedure SNMPSupport, $(!DLLSQL), IsDlgBtnChecked $(DlgOpts), "UNIBUTTON10"
  2542.         
  2543.         LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenSetupKey),$(!RegValSQLPath),$(!RegTypeString),$(!SQLPath),""
  2544.         
  2545.         LibraryProcedure OpenParamKey, $(!DLLSQL), RegMakeKey "\\"$(!ComputerName),$(!RegSQLServerServer),$(!RegSQLSvrParam),$(!AdminACL)
  2546.         ifstr(i) $(OpenParamKey) == "KEY_ERROR"
  2547.             read-syms ErrorUpdatingRegistry$(!STF_LANGUAGE)
  2548.             LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)
  2549.         else
  2550.             ifstr(i) $(EMDBEntry) != ""
  2551.                 LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenParamKey),$(EMDBEntry),$(!RegTypeString),"-d"$(!MasterDBPath)"\"$(!MasterDBFileName),""
  2552.             else
  2553.                 LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenParamKey),$(!RegValParameter)$(ParamCount),$(!RegTypeString),"-d"$(!MasterDBPath)"\"$(!MasterDBFileName),""
  2554.                 set-add ParamCount = $(ParamCount),1
  2555.             endif
  2556.             ifstr(i) $(ELogPath) == ""
  2557.                 ifstr(i) $(ELogEntry) != ""
  2558.                     LibraryProcedure Result, $(!DLLSQL), RegDelValue $(OpenParamKey),$(ELogEntry)
  2559.                 endif
  2560.             else
  2561.                 ifstr(i) $(ELogEntry) != ""
  2562.                     LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenParamKey),$(ELogEntry),$(!RegTypeString),"-e"$(ELogPath),""
  2563.                 else
  2564.                     LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenParamKey),$(!RegValParameter)$(ParamCount),$(!RegTypeString),"-e"$(ELogPath),""
  2565.                 endif
  2566.             endif
  2567.             LibraryProcedure Result, $(!DLLSQL), RegClose $(OpenParamKey)
  2568.         endif
  2569.         
  2570.         ifstr(i) $(NTELog) == "CHECKED"
  2571.             shell "" RegWriteELog "\\"$(!ComputerName)
  2572.             ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  2573.                 goto end_serveropts
  2574.             endif
  2575.         else-ifstr(i) $(NTELogInitial) == "CHECKED"
  2576.             LibraryProcedure MntrRunning, $(!DLLSQL), GetServiceState "\\"$(!ComputerName),$(!SQLMonitorService)
  2577.             ifstr(i) $(MntrRunning) == "SERVICE_RUNNING"
  2578.                 shell "" StopService $(!SQLMonitorService)
  2579.             endif
  2580.             LibraryProcedure SchedRunning, $(!DLLSQL), GetServiceState "\\"$(!ComputerName),$(!SQLSchedulerService)
  2581.             ifstr(i) $(SchedRunning) == "SERVICE_RUNNING"
  2582.                 shell "" StopService $(!SQLSchedulerService)
  2583.             endif
  2584.             LibraryProcedure OldSchedRunning, $(!DLLSQL), GetServiceState "\\"$(!ComputerName),$(!SQLOldSchedulerService)
  2585.             ifstr(i) $(OldSchedRunning) == "SERVICE_RUNNING"
  2586.                 shell "" StopService $(!SQLOldSchedulerService)
  2587.             endif
  2588.             LibraryProcedure SvrRunning, $(!DLLSQL), GetServiceState "\\"$(!ComputerName),$(!SQLServerService)
  2589.             ifstr(i) $(SvrRunning) == "SERVICE_RUNNING"
  2590.                 shell "" StopService $(!SQLServerService)
  2591.             endif
  2592.             LibraryProcedure SvrRunning, $(!DLLSQL), GetServiceState "\\"$(!ComputerName),$(!SQLSchedulerService)
  2593.             ifstr(i) $(SvrRunning) == "SERVICE_RUNNING"
  2594.                 shell "" StopService $(!SQLSchedulerService)
  2595.             endif
  2596.             LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$(!ComputerName),"UNIDELETE",$(!RegEventAppLog),$(!SQLServerService)
  2597.             LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$(!ComputerName),"UNIDELETE",$(!RegEventAppLog),$(!SQLSchedulerService)
  2598.             LibraryProcedure Result, $(!DLLSQL), ClearEventLogNoBackup
  2599.             ifstr(i) $(SvrRunning) == "SERVICE_RUNNING"
  2600.                 shell "" StartService $(!SQLServerService)
  2601.             endif
  2602.             ifstr(i) $(SchedRunning) == "SERVICE_RUNNING"
  2603.                 shell "" StartService $(!SQLSchedulerService)
  2604.             endif
  2605.         endif
  2606.         
  2607.         shell "" RegWriteSystemPaths "\\"$(!ComputerName),$(!RegSystemPaths),""
  2608.         ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  2609.             goto end_serveropts
  2610.         endif
  2611.         
  2612.         ifstr(i) $(OpenSvcKey) != ""
  2613.             ifstr(i) $(SvcStart) == "CHECKED"
  2614.                 LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenSvcKey),$(!RegSvcStart),$(!RegTypeDWord),"2",""
  2615.             else
  2616.                 LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenSvcKey),$(!RegSvcStart),$(!RegTypeDWord),"3",""
  2617.             endif
  2618.         endif
  2619.         
  2620.         ifstr(i) $(OpenMonSvcKey) != ""
  2621.             ifstr(i) $(MonSvcStart) == "CHECKED"
  2622.                 LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenMonSvcKey),$(!RegSvcStart),$(!RegTypeDWord),"2",""
  2623.             else
  2624.                 LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenMonSvcKey),$(!RegSvcStart),$(!RegTypeDWord),"3",""
  2625.             endif
  2626.         endif
  2627.         
  2628.         ifstr(i) $(OpenServerKey) != ""
  2629.             ifstr(i) $(!CopyMailInfo) == "CHECKED"
  2630.                 shell "" RegCopyMailInfo "\\"$(!ComputerName)
  2631.             endif
  2632.             
  2633.             ifstr(i) $(!MSMailUser) != ""
  2634.                 LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenServerKey),$(!RegValMSMailUser),$(!RegTypeString),$(!MSMailUser),""
  2635.                 LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenServerKey),$(!RegValMSMailPwd),$(!RegTypeString),$(!MSMailPwd),""
  2636.             endif
  2637.             
  2638.             ifstr(i) $(MailInfo) == "CHECKED"
  2639.                 ifstr(i) $(MailInitial) != "CHECKED"
  2640.                     shell "" RegWriteMailEnabled "\\"$(!ComputerName), $(!RegValSqlMailPair)
  2641.                 endif
  2642.             else
  2643.                 shell "" DoMailNuke "\\"$(!ComputerName), $(!RegValSqlMailPair)
  2644.             endif
  2645.  
  2646.             ifstr(i) $(ImpClient) == "CHECKED"
  2647.                 LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenServerKey),$(!RegValClientImp),$(!RegTypeDWord),"1",""
  2648.             else
  2649.                 LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenServerKey),$(!RegValClientImp),$(!RegTypeDWord),"0",""
  2650.             endif
  2651.         endif
  2652.         
  2653.         ifstr(i) $(DoSQLCntrs) == "CHECKED"
  2654.             ifstr(i) $(SQLPerf) == ""
  2655.                 shell "" RegWritePerfMon "\\"$(!ComputerName)
  2656.             endif
  2657.             ifstr(i) $(PerfSync) == "CHECKED"
  2658.                 LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenPerfKey),$(!RegValPerfSync),$(!RegTypeDWord),"0",""
  2659.             else
  2660.                 LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenPerfKey),$(!RegValPerfSync),$(!RegTypeDWord),"1",""
  2661.             endif
  2662.         else
  2663.             ifstr(i) $(SQLPerf) != ""
  2664.                 shell "" DoPerfmonNuke "\\"$(!ComputerName)
  2665.             endif
  2666.         endif
  2667.         
  2668.         ifstr(i) $(SNMPSupport) == "CHECKED"
  2669.             ifstr(i) $(SNMPInitial) != "CHECKED"
  2670.                 shell "" RegWriteSNMP
  2671.             endif
  2672.         else
  2673.             ifstr(i) $(SNMPInitial) == "CHECKED"
  2674.                 LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$(!ComputerName),"UNIDELETE",$(!RegSQLServer)"\"$(!RegSQLSNMP),$(!RegCurrentVer)
  2675.                 LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$(!ComputerName),"UNIDELETE",$(!RegSQLServer),$(!RegSQLSNMP)
  2676.                 shell "" DoNukeSQLSNMPAgent
  2677.             endif
  2678.         endif
  2679.         
  2680.         set Status = "STATUS_SUCCESSFUL"
  2681.     else
  2682.         goto serveropts
  2683.     endif
  2684. end_serveropts =+
  2685.     ifstr(i) $(OpenSvcKey) != ""
  2686.         LibraryProcedure Result, $(!DLLSQL), RegClose $(OpenSvcKey)
  2687.     endif
  2688.     ifstr(i) $(OpenMonSvcKey) != ""
  2689.         LibraryProcedure Result, $(!DLLSQL), RegClose $(OpenMonSvcKey)
  2690.     endif
  2691.     ifstr(i) $(OpenSetupKey) != ""
  2692.         LibraryProcedure Result, $(!DLLSQL), RegClose $(OpenSetupKey)
  2693.     endif
  2694.     ifstr(i) $(OpenServerKey) != ""
  2695.         LibraryProcedure Result, $(!DLLSQL), RegClose $(OpenServerKey)
  2696.     endif
  2697.     ifstr(i) $(OpenPerfKey) != ""
  2698.         LibraryProcedure Result, $(!DLLSQL), RegClose $(OpenPerfKey)
  2699.     endif
  2700.     EndWait
  2701.     LibraryProcedure Result, $(!DLLSQL), CloseDialog $(DlgOpts)
  2702.     Return $(Status)
  2703.         
  2704. [DoParseServerInfo]
  2705.     StartWait
  2706.     set Status = "STATUS_FAILED"
  2707.     set ELogEntry = ""
  2708.     set ELogPath = ""
  2709.     set EMDBEntry = ""
  2710.     set NTELog = ""
  2711.     set ParamCount = ""
  2712.     set SvcStart = ""
  2713.     set SvcMonStart = ""
  2714.     set SQLPerf = ""
  2715.     set SQLPerfSync = "0"
  2716.     set !MasterDBPath = ""
  2717.     set !MasterDBFileName = ""
  2718.     set !SQLPath = ""
  2719.     
  2720.     LibraryProcedure OpenSetupKey, $(!DLLSQL), RegMakeKey "\\"$(!ComputerName),$(!RegSQLSetup),"",""
  2721.     ifstr(i) $(OpenSetupKey) != "KEY_ERROR"
  2722.         LibraryProcedure !SQLPath, $(!DLLSQL), RegRead $(OpenSetupKey),$(!RegValSQLPath)
  2723.     endif
  2724.     
  2725.     LibraryProcedure TmpParamList, $(!DLLSQL), RegEnumKeyValues "\\"$(!ComputerName),$(!RegSQLServerServer)"\"$(!RegSQLSvrParam),"VALUENAMES"
  2726.     QueryListSize ParamCount $(TmpParamList)
  2727.     LibraryProcedure Result, $(!DLLSQL), RegClose $(OpenPerfKey)
  2728.     
  2729.     shell "" DoExtractMasterAndErrorlog "\\"$(!ComputerName)
  2730.     set EMDBEntry = $($R0)
  2731.     set ELogEntry = $($R1)
  2732.     set !MasterDBPath = $($R2)
  2733.     set ELogPath = $($R3)
  2734.     set !MasterDBFileName = $($R4)
  2735.     
  2736.     LibraryProcedure OpenELogKey, $(!DLLSQL), RegMakeKey "\\"$(!ComputerName),$(!RegEventAppLog),$(!SQLServerService),$(!AdminACL)
  2737.     ifstr(i) $(OpenELogKey) != "KEY_ERROR"
  2738.         LibraryProcedure NTELog, $(!DLLSQL), RegRead $(OpenELogKey),$(!RegValELogMsgFile)
  2739.         LibraryProcedure Result, $(!DLLSQL), RegClose $(OpenELogKey)
  2740.     endif
  2741.     
  2742.     LibraryProcedure OpenSvcKey, $(!DLLSQL), RegMakeKey "\\"$(!ComputerName),$(!RegSCM),$(!SQLServerService),$(!AdminACL)
  2743.     ifstr(i) $(OpenSvcKey) != "KEY_ERROR"
  2744.         LibraryProcedure SvcStart, $(!DLLSQL), RegRead $(OpenSvcKey),$(!RegSvcStart)
  2745.     else
  2746.         set OpenSvcKey = ""
  2747.     endif
  2748.     
  2749.     LibraryProcedure OpenSchKey, $(!DLLSQL), RegMakeKey "\\"$(!ComputerName),$(!RegSCM),$(!SQLSchedulerService),$(!AdminACL)
  2750.     ifstr(i) $(OpenSchKey) != "KEY_ERROR"
  2751.         LibraryProcedure SvcMonStart, $(!DLLSQL), RegRead $(OpenSchKey),$(!RegSvcStart)
  2752.     else
  2753.         set OpenSchKey = ""
  2754.     endif
  2755.     ifstr(i) $(!InstallType) != "1"
  2756.         ifstr(i) $(!SQL95Keys) != "TRUE"
  2757.             LibraryProcedure Result, $(!DLLSQL), DoServiceOp "\\"$(!ComputerName),"SERVICE_REMOVE",$(!SQLMonitorService),"",""
  2758.         endif
  2759.     endif
  2760.     LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$(!ComputerName),"UNIDELETE",$(!RegSQLServer),$(!SQLMonitorService)"\"$(!RegSQLSvrParam)
  2761.     LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$(!ComputerName),"UNIDELETE",$(!RegSQLServer),$(!SQLMonitorService)
  2762.     
  2763.     LibraryProcedure OpenServerKey, $(!DLLSQL), RegMakeKey "\\"$(!ComputerName),$(!RegSQLServer),$(!RegSQLServerSvr),$(!AdminACL)
  2764.     ifstr(i) $(OpenServerKey) != "KEY_ERROR"
  2765.         LibraryProcedure TmpStartupHandlers, $(!DLLSQL), RegRead $(OpenServerKey),$(!RegValMailEnabled)
  2766.         LibraryProcedure ImpersonateClient, $(!DLLSQL), RegRead $(OpenServerKey),$(!RegValClientImp)
  2767.         
  2768.     else
  2769.         set OpenServerKey = ""
  2770.     endif
  2771.     
  2772.     LibraryProcedure OpenPerfKey, $(!DLLSQL), RegMakeKey "\\"$(!ComputerName),$(!RegSCM),$(!SQLServerService)"\"$(!RegSQLPerformance),$(!AdminACL)
  2773.     ifstr(i) $(OpenPerfKey) != "KEY_ERROR"
  2774.         LibraryProcedure SQLPerf, $(!DLLSQL), RegRead $(OpenPerfKey),$(!RegValLibrary)
  2775.         ifstr(i) $(SQLPerf) == "KEY_ERROR"
  2776.             set SQLPerf = ""
  2777.         endif
  2778.         LibraryProcedure SQLPerfSync, $(!DLLSQL), RegRead $(OpenPerfKey),$(!RegValPerfSync)
  2779.         ifstr(i) $(SQLPerf) == "KEY_ERROR"
  2780.             set SQLPerfSync = "0"
  2781.         endif
  2782.     endif
  2783.     
  2784.     ifstr(i) $(!SQLPath) == "KEY_ERROR"
  2785.         set !SQLPath = ""
  2786.     endif
  2787.     LibraryProcedure Result, $(!DLLSQL), DlgSetEditText $($0),"EDIT1",$(!SQLPath)
  2788.     ifstr(i) $(!MasterDBPath) == "KEY_ERROR"
  2789.         set !MasterDBPath = ""
  2790.     endif
  2791.     ifstr(i) $(!MasterDBFileName) == "KEY_ERROR"
  2792.         set !MasterDBFileName = ""
  2793.     endif
  2794.     LibraryProcedure Result, $(!DLLSQL), DlgSetEditText $($0),"EDIT2",$(!MasterDBPath)"\"$(!MasterDBFileName)
  2795.     LibraryProcedure Result, $(!DLLSQL), DlgSetEditText $($0),"EDIT3",$(ELogPath)
  2796.     ifstr(i) $(NTELog) == "KEY_ERROR"
  2797.         set NTELog = ""
  2798.     endif
  2799.     
  2800.     LibraryProcedure SNMPInstalled, $(!DLLSQL), GetServiceState "\\"$(!ComputerName), $(!SNMPService)
  2801.     ifstr(i) $(SNMPInstalled) == "SERVICE_NOT_EXIST"
  2802.         LibraryProcedure rc, $(!DLLSQL), EnableDlgBtn $($0), "UNIBUTTON10", "FALSE"
  2803.     else
  2804.         LibraryProcedure rc, $(!DLLSQL), EnableDlgBtn $($0), "UNIBUTTON10", "TRUE"
  2805.         LibraryProcedure OpenSQLSNMPKey, $(!DLLSQL), RegOpen "\\"$(!ComputerName), $(!RegSQLServer)"\"$(!RegSQLSNMP)
  2806.         ifstr(i) $(OpenSQLSNMPKey) == "KEY_ERROR"
  2807.             LibraryProcedure rc, $(!DLLSQL), DlgCheckButton $($0), "UNIBUTTON10", "FALSE"
  2808.         else
  2809.             LibraryProcedure rc, $(!DLLSQL), DlgCheckButton $($0), "UNIBUTTON10", "TRUE"
  2810.         endif
  2811.     endif
  2812.     
  2813.     ifstr(i) $($1) == "FALSE"
  2814.         ifstr(i) $(NTELog) != ""
  2815.             LibraryProcedure Result, $(!DLLSQL), DlgCheckButton $($0),"UNIBUTTON4","TRUE"
  2816.         else
  2817.             LibraryProcedure Result, $(!DLLSQL), DlgCheckButton $($0),"UNIBUTTON4","FALSE"
  2818.         endif
  2819.         ifstr(i) $(SvcStart) == "KEY_ERROR"
  2820.             set SvcStart = ""
  2821.         endif
  2822.         ifstr(i) $(SvcStart) == "2"
  2823.             LibraryProcedure Result, $(!DLLSQL), DlgCheckButton $($0),"DLGBUTTON4","TRUE"
  2824.         else
  2825.             LibraryProcedure Result, $(!DLLSQL), DlgCheckButton $($0),"DLGBUTTON4","FALSE"
  2826.         endif
  2827.         
  2828.         ifstr(i) $(SvcMonStart) == "KEY_ERROR"
  2829.             set SvcMonStart = ""
  2830.         endif
  2831.         ifstr(i) $(SvcMonStart) == "2"
  2832.             LibraryProcedure Result, $(!DLLSQL), DlgCheckButton $($0),"DLGBUTTON5","TRUE"
  2833.         else
  2834.             LibraryProcedure Result, $(!DLLSQL), DlgCheckButton $($0),"DLGBUTTON5","FALSE"
  2835.         endif
  2836.         ifstr(i) $(ImpersonateClient) == "KEY_ERROR"
  2837.             set ImpersonateClient = "0"
  2838.         endif
  2839.         ifstr(i) $(ImpersonateClient) == "1"
  2840.             LibraryProcedure Result, $(!DLLSQL), DlgCheckButton $($0),"UNIBUTTON9","TRUE"
  2841.         else
  2842.             LibraryProcedure Result, $(!DLLSQL), DlgCheckButton $($0),"UNIBUTTON9","FALSE"
  2843.         endif
  2844.         
  2845.         ifcontains(i) $(!RegValSqlMailPair) in $(TmpStartupHandlers)
  2846.             LibraryProcedure Result, $(!DLLSQL), DlgCheckButton $($0),"UNIBUTTON2","TRUE"
  2847.         else
  2848.             LibraryProcedure Result, $(!DLLSQL), DlgCheckButton $($0),"UNIBUTTON2","FALSE"
  2849.         endif
  2850.         ifstr(i) $(SQLPerf) != ""
  2851.             LibraryProcedure Result, $(!DLLSQL), DlgCheckButton $($0),"DLGBUTTON3","TRUE"
  2852.             LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $($0),"UNIBUTTON6","TRUE"
  2853.             LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $($0),"UNIBUTTON7","TRUE"
  2854.         else
  2855.             LibraryProcedure Result, $(!DLLSQL), DlgCheckButton $($0),"DLGBUTTON3","FALSE"
  2856.             LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $($0),"UNIBUTTON6","FALSE"
  2857.             LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $($0),"UNIBUTTON7","FALSE"
  2858.         endif
  2859.         
  2860.         ifstr(i) $(SQLPerfSync) == "1"
  2861.             LibraryProcedure Result, $(!DLLSQL), DlgCheckButton $($0),"UNIBUTTON7","UNIBUTTON6","UNIBUTTON7"
  2862.         else
  2863.             LibraryProcedure Result, $(!DLLSQL), DlgCheckButton $($0),"UNIBUTTON6","UNIBUTTON6","UNIBUTTON7"
  2864.         endif
  2865.         
  2866.     endif
  2867.     EndWait
  2868.     Return $(Status),$(OpenSetupKey),$(OpenSvcKey),$(SQLPerf),$(ELogEntry),$(EMDBEntry),$(ParamCount),$(OpenSchKey),$(OpenServerKey),$(OpenPerfKey)
  2869.         
  2870. [DoExtractMasterAndErrorlog]
  2871.     LibraryProcedure TmpParamList, $(!DLLSQL), RegEnumKeyValues $($0),$(!RegSQLServerServer)"\"$(!RegSQLSvrParam),"VALUENAMESNDATA"
  2872.     ForListDo $(TmpParamList)
  2873.         LibraryProcedure Idx, $(!DLLSQL), IntMultiply $(#),2
  2874.         set Data = *($(TmpParamList),$(Idx))
  2875.         ifstr(i) $(Data) != ""
  2876.             LibraryProcedure Result, $(!DLLSQL), StringCopyN $(Data),"0","2"
  2877.             set-sub Idx = $(Idx),1
  2878.             ifstr(i) $(Result) == "-e"
  2879.                 set ErrorLogEntry = *($(TmpParamList),$(Idx))
  2880.                 LibraryProcedure ErrorLogData, $(!DLLSQL), StringCopyN $(Data),"2","N"
  2881.             else-ifstr(i) $(Result) == "-d"
  2882.                 set MasterDBEntry = *($(TmpParamList),$(Idx))
  2883.                 LibraryProcedure Tmp, $(!DLLSQL), StringCopyN $(Data),"2","N"
  2884.                 LibraryProcedure MasterDBData, $(!DLLSQL), StrBeforeAndAfter $(Tmp),"LASTBEFORE","\"
  2885.                 LibraryProcedure MasterName, $(!DLLSQL), StrBeforeAndAfter $(Tmp),"LASTAFTER","\"
  2886.             endif
  2887.         endif
  2888.     endif
  2889. EndForListDo
  2890.     Return $(MasterDBEntry),$(ErrorLogEntry),$(MasterDBData),$(ErrorLogData),$(MasterName)
  2891.         
  2892. [DoGetLangInfo]
  2893.     set Status = "STATUS_FAILED"
  2894.     read-syms GetLangInfoDlg$(!STF_LANGUAGE)
  2895.     LibraryProcedure DlgLang, $(!DLLSQL), SQLDlgDisplay $(STF_HWND),$(DlgTemplate),"",$(!SQLDlgNames),"MODAL",""
  2896. lang_info =+
  2897.     LibraryProcedure DLGEVENT, $(!DLLSQL), WaitEvent
  2898.     ifstr(i) $(DLGEVENT) == "EXIT"
  2899.         shell "" QueryUserQuit $(!STF_LANGUAGE)
  2900.         ifstr(i) $($R1) == "OK"
  2901.             set Status = "STATUS_USERQUIT"
  2902.             goto end_langinfo
  2903.         else
  2904.             goto lang_info
  2905.         endif
  2906.     else-ifstr(i) $(DLGEVENT) == "CONTINUE"
  2907.         LibraryProcedure LanguageName, $(!DLLSQL), DlgGetEditText $(DlgLang),"EDIT1"
  2908.         LibraryProcedure SAPassword, $(!DLLSQL), DlgGetEditText $(DlgLang),"EDIT2"
  2909.         ifstr(i) $(LanguageName) == ""
  2910.             read-syms NoLangInfo$(!STF_LANGUAGE)
  2911.             shell "" MessageError
  2912.             goto lang_info
  2913.         endif
  2914.         LibraryProcedure DefaultLanguage, $(!DLLSQL), IsDlgBtnChecked $(DlgLang),"UNIBUTTON1"
  2915.     else-ifstr(i) $(DLGEVENT) == "BACK"
  2916.         set Status = "STATUS_BACK"
  2917.         goto end_langinfo
  2918.     endif
  2919.     set Status = "STATUS_SUCCESSFUL"
  2920. end_langinfo =+
  2921.     LibraryProcedure Result, $(!DLLSQL), CloseDialog $(DlgLang)
  2922.     Return $(Status) $(LanguageName) $(SAPassword) $(DefaultLanguage)
  2923.     
  2924. [DoRebuildDatabase]
  2925.     set Status = "STATUS_FAILED"
  2926. backToRebuildQ =+
  2927.     read-syms RebuildDlg$(!STF_LANGUAGE)
  2928.     LibraryProcedure DlgRbld, $(!DLLSQL), SQLDlgDisplay $(STF_HWND),$(DlgTemplate),"",$(!SQLDlgNames),"MODAL",""
  2929. rebuild =+
  2930.     LibraryProcedure DLGEVENT, $(!DLLSQL), WaitEvent
  2931.     ifstr(i) $(DLGEVENT) == "BACK"
  2932.         set Status = "STATUS_BACK"
  2933.         goto finish_rebuild
  2934.     else-ifstr(i) $(DLGEVENT) == "EXIT"
  2935.         shell "" QueryUserQuit $(!STF_LANGUAGE)
  2936.         ifstr(i) $($R1) == "OK"
  2937.             set Status = "STATUS_USERQUIT"
  2938.             goto finish_rebuild
  2939.         else
  2940.             goto rebuild
  2941.         endif
  2942.     else-ifstr(i) $(DLGEVENT) == "CONTINUE"
  2943.         LibraryProcedure Result, $(!DLLSQL), CloseDialog $(DlgRbld)
  2944.         set DlgRbld = ""
  2945.         
  2946.         set !AddlScripts = $(!DefScriptList)
  2947.         set !CheckInstList = $(!CheckInstDefList)
  2948.         set !CheckInstRetList = $(!CheckInstDefRetList)
  2949.         set !CheckInstList = >( $(!CheckInstList), $(!SQLPubs))
  2950.         set !CheckInstRetList = >( $(!CheckInstRetList), $(!Pubs))
  2951.         set !CheckInstList = >( $(!CheckInstList), $(!SQLXPStar1))
  2952.         set !CheckInstList = >( $(!CheckInstList), $(!SQLXPStar2))
  2953.         set !CheckInstList = >( $(!CheckInstList), $(!SQLOle1))
  2954.         set !CheckInstRetList = >( $(!CheckInstRetList), $(!XpStarChk1))
  2955.         set !CheckInstRetList = >( $(!CheckInstRetList), $(!XpStarChk2))
  2956.         set !CheckInstRetList = >( $(!CheckInstRetList), $(!SQLOleChk1))
  2957.         set !CheckInstList = >( $(!CheckInstList), $(!SQLHelpSQL))
  2958.         set !CheckInstRetList = >( $(!CheckInstRetList), $(!RetHelpSQL))
  2959.         
  2960.         set !SortOrderSelList = $(!SortISOSelList)
  2961.         set !TheCharSet       = *( $(!CharSetSelList), 2 )
  2962.         LibraryProcedure Idx, $(!DLLSQL), IntMultiply $(!DefSortFileIndex), "3"
  2963.         set !TheSortConfigValue = *( $(!SortOrderSelList),$(Idx) )
  2964.         set-sub Idx = $(Idx),1
  2965.         set !TheSortFile = *( $(!SortOrderSelList), $(Idx) )
  2966.         
  2967. backToRebuildOpts =+
  2968.         shell "" DoGetRebuildOptions
  2969.         ifstr(i) $($R0) == "STATUS_BACK"
  2970.             goto backToRebuildQ
  2971.         else-ifstr(i) $($R0) == "STATUS_USERQUIT"
  2972.             goto finish_rebuild
  2973.         endif
  2974.         
  2975. backToSQLPath =+
  2976.         shell "" DoGetSpaceSQLPath GetSQLPathDlg,$(InstallationReqSpace),$(SpaceCost),"1","","",$(!LogicalSQLDrive)
  2977.         ifstr(i) $($R0) == "STATUS_BACK"
  2978.             goto backToRebuildOpts
  2979.         else-ifstr(i) $($R0) == "STATUS_USERQUIT"
  2980.             set Status = "STATUS_USERQUIT"
  2981.             goto finish_rebuild
  2982.         else-ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  2983.             goto finish_rebuild
  2984.         endif
  2985.         set !SQLPath = $($R1)$($R2)
  2986.         set !DefSQLPath = $(!SQLPath)
  2987.         set !CreateSQLPath = $(!SQLPath)
  2988.         ifstr(i) $(!RemoteComputer) == ""
  2989.             set !LogicalSQLDrive = $($R1)
  2990.         endif
  2991.         
  2992. backToMasterPath =+
  2993.         ifstr(i) $(!MasterDBFileName) == ""
  2994.             set !DefMasterPath = $(!SQLPath)"\"$(!DataDir)"\"$(!DefMasterDB)
  2995.         else
  2996.             set !DefMasterPath = $(!MasterDBPath)"\"$(!MasterDBFileName)
  2997.         endif
  2998.         shell "" DoGetSpaceMasterPath GetMasterPathDlg,$(InstallationReqSpace),$(SpaceCost),"1","","MASTER_DONT_CARE_EXIST",$(!LogicalDBDrive)
  2999.         ifstr(i) $($R0) == "STATUS_BACK"
  3000.             goto backToSQLPath
  3001.         else-ifstr(i) $($R0) == "STATUS_USERQUIT"
  3002.             set Status = "STATUS_USERQUIT"
  3003.             goto finish_rebuild
  3004.         else-ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  3005.             goto finish_rebuild
  3006.         endif
  3007.         
  3008.         shell "" StopService $(!SQLMonitorService)
  3009.         ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  3010.             goto finish_rebuild
  3011.         endif
  3012.         shell "" StopService $(!SQLSchedulerService)
  3013.         ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  3014.             goto finish_rebuild
  3015.         endif
  3016.         shell "" StopService $(!SQLOldSchedulerService)
  3017.         ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  3018.             goto finish_rebuild
  3019.         endif
  3020.         shell "" StopService $(!SQLServerService)
  3021.         ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  3022.             goto finish_rebuild
  3023.         endif
  3024.         LibraryProcedure OpenSetupKey, $(!DLLSQL), RegMakeKey "\\"$(!ComputerName),$(!RegSQLSetup),"",""
  3025.         ifstr(i) $(OpenSetupKey) != "KEY_ERROR"
  3026.             LibraryProcedure Result, $(!DLLSQL), RegDelValue $(OpenSetupKey),$(!RegValSetupState)
  3027.             LibraryProcedure Result, $(!DLLSQL), RegClose $(OpenSetupKey)
  3028.         endif
  3029.         shell "" DoReBuild "FALSE"
  3030.         ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  3031.             goto finish_rebuild
  3032.         endif
  3033.         set Status = "STATUS_SUCCESSFUL"
  3034.         shell "" StartService $(!SQLServerService)
  3035.         LibraryProcedure OpenSetupKey, $(!DLLSQL), RegMakeKey "\\"$(!ComputerName),$(!RegSQLSetup),"",""
  3036.         ifstr(i) $(OpenSetupKey) != "KEY_ERROR"
  3037.             LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenSetupKey),$(!RegValSetupState),$(!RegTypeString),$(!RegValInstalled),""
  3038.             LibraryProcedure Result, $(!DLLSQL), RegClose $(OpenSetupKey)
  3039.         endif
  3040.     endif
  3041. finish_rebuild =+
  3042.     ifstr(i) $(DlgRbld) != ""
  3043.         LibraryProcedure Result, $(!DLLSQL), CloseDialog $(DlgRbld)
  3044.     endif
  3045.     Return $(Status)
  3046.         
  3047. [DoGetRebuildOptions]
  3048.     StartWait
  3049.     set Status = "STATUS_FAILED"
  3050.     read-syms RebuildOptionsDlg
  3051.     LibraryProcedure DlgRebOptions, $(!DLLSQL), SQLDlgDisplay $(STF_HWND),$(DlgTemplate),"",$(!SQLDlgNames),"MODAL",""
  3052.     EndWait
  3053.     reboptions = +
  3054.     LibraryProcedure DLGEVENT, $(!DLLSQL), WaitEvent
  3055.     ifstr(i) $(DLGEVENT) == "EXIT"
  3056.         shell "" QueryUserQuit $(!STF_LANGUAGE)
  3057.         ifstr(i) $($R1) == "OK"
  3058.             set Status = "STATUS_USERQUIT"
  3059.             goto finish_reboptions
  3060.         else
  3061.             goto reboptions
  3062.         endif
  3063.     else-ifstr(i) $(DLGEVENT) == "BACK"
  3064.         set Status = "STATUS_BACK"
  3065.         goto finish_reboptions
  3066.     else-ifstr(i) $(DLGEVENT) == "CONTINUE"
  3067.         set !TheCharSetPath = $(!SQLPath)"\"$(!CharSets)"\"$(!TheCharSet)
  3068.         set Status = "STATUS_SUCCESSFUL"
  3069.         goto finish_reboptions
  3070.     else-ifstr(i) $(DLGEVENT) == "DLGBUTTON1"
  3071.         shell "" DoCharSet
  3072.         goto reboptions
  3073.     else-ifstr(i) $(DLGEVENT) == "DLGBUTTON2"
  3074.         shell "" DoSortOrder
  3075.         goto reboptions
  3076.     endif
  3077.     finish_reboptions = +
  3078.     LibraryProcedure Result, $(!DLLSQL), CloseDialog $(DlgRebOptions)
  3079.     Return $(Status)
  3080.         
  3081. [DoNetDefaults]
  3082.     set !StreetName = $(!ComputerName)
  3083.     set !TCPIPSocketNumber = $(!DefTCPIPSocket)
  3084.     set !SocketNumber = $(!DefSocketNumber)
  3085.     set !ServiceName = $(!ComputerName)
  3086.     set !ADSPServiceName = $(!ComputerName)
  3087.     set !DECNetObjectID = $(!DefDECNetObjectID)
  3088.     ifstr(i) $(!IntegratedSecurity) == "TRUE"
  3089.         set !NetworkSelList = $(!DefSecNetworkSelList)
  3090.     else
  3091.         ifstr(i) $(!RISCInst) == "YES"
  3092.             set !NetworkSelList = $(!DefNetworkRISCSelList)
  3093.         else
  3094.             set !NetworkSelList = $(!DefNetworkSelList)
  3095.         endif
  3096.     endif
  3097.     set !NetAddresses = {}
  3098.     ifstr(i) $(!InstallType) == "1"
  3099.         set !NetLibList = $(!NetLibDefList)
  3100.     else-ifstr(i) $(!InstallType) == "2"
  3101.         set !NetLibList = $(!OldListenOn)
  3102.     else-ifstr(i) $(!RegistryRebuild) != ""
  3103.         set !NetLibList = $(!NetLibDefList)
  3104.     else
  3105.         set !NetLibList = {}
  3106.     endif
  3107.     Return
  3108.         
  3109. [DoNetInstall]
  3110.     set Status   = "STATUS_FAILED"
  3111.     set !ServerNMPipeName = $(!SvrPipe)
  3112. net_intsall =+
  3113.     set BillyBoard = ""
  3114.     shell "" DoNetDefaults
  3115.     read-syms NetInstallError$(!STF_LANGUAGE)
  3116.     LibraryProcedure OpenServerKey, $(!DLLSQL), RegMakeKey "\\"$(!ComputerName),$(!RegSQLServer),$(!RegSQLServerSvr),$(!AdminACL)
  3117.     ifstr(i) $(OpenServerKey) == "KEY_ERROR"
  3118.         read-syms ErrorReadRegistry$(!STF_LANGUAGE)
  3119.         LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)
  3120.         goto end_net_install
  3121.     endif
  3122.     LibraryProcedure !ListenOn, $(!DLLSQL), RegRead $(OpenServerKey),$(!RegValListenOn)
  3123.     ForListDo $(!ListenOn)
  3124.         LibraryProcedure Before, $(!DLLSQL), StrBeforeAndAfter $($),"BEFORE",","
  3125.         LibraryProcedure After, $(!DLLSQL), StrBeforeAndAfter $($),"AFTER",","
  3126.         ifcontains(i) $(Before) in $(!NetLibList)
  3127.         else
  3128.             ifstr(i) $(Before) == $(!NetLibPipes)
  3129.                 set !ServerNMPipeName = $(After)
  3130.                 set !NetLibList = >( $(!NetLibList), $(!NetLibPipes))
  3131.                 set !NetSelList = >( $(!NetSelList), *($(!NetworkSelList), 1))
  3132.                 set !NetSelList = >( $(!NetSelList), *($(!NetworkSelList), 2))
  3133.                 set !NetSelList = >( $(!NetSelList), *($(!NetworkSelList), 3))
  3134.             else-ifstr(i) $(Before) == $(!NetLibRPC)
  3135.                 set !NetLibList = >( $(!NetLibList), $(!NetLibRPC))
  3136.                 set !NetSelList = >( $(!NetSelList), *($(!NetworkSelList), 4))
  3137.                 set !NetSelList = >( $(!NetSelList), *($(!NetworkSelList), 5))
  3138.                 set !NetSelList = >( $(!NetSelList), *($(!NetworkSelList), 6))
  3139.             else-ifstr(i) $(Before) == $(!NetLibSPX)
  3140.                 set !NetLibList = >( $(!NetLibList), $(!NetLibSPX))
  3141.                 LibraryProcedure !ServiceName, $(!DLLSQL), StrBeforeAndAfter $(After),"BEFORE",","
  3142.                 LibraryProcedure !SocketNumber, $(!DLLSQL), StrBeforeAndAfter $(After),"AFTER",","
  3143.                 set !NetSelList = >( $(!NetSelList), *($(!NetworkSelList), 7))
  3144.                 set !NetSelList = >( $(!NetSelList), *($(!NetworkSelList), 8))
  3145.                 set !NetSelList = >( $(!NetSelList), *($(!NetworkSelList), 9))
  3146.             else-ifstr(i) $(Before) == $(!NetLibTCPIP)
  3147.                 set !NetLibList = >( $(!NetLibList), $(!NetLibTCPIP))
  3148.                 set !TCPIPSocketNumber = $(After)
  3149.                 set !NetSelList = >( $(!NetSelList), *($(!NetworkSelList), 10))
  3150.                 set !NetSelList = >( $(!NetSelList), *($(!NetworkSelList), 11))
  3151.                 set !NetSelList = >( $(!NetSelList), *($(!NetworkSelList), 12))
  3152.             else-ifstr(i) $(Before) == $(!NetLibADSP)
  3153.                 set !NetLibList = >( $(!NetLibList), $(!NetLibADSP))
  3154.                 set !ADSPServiceName = $(After)
  3155.                 set !NetSelList = >( $(!NetSelList), *($(!NetworkSelList), 13))
  3156.                 set !NetSelList = >( $(!NetSelList), *($(!NetworkSelList), 14))
  3157.                 set !NetSelList = >( $(!NetSelList), *($(!NetworkSelList), 15))
  3158.             else-ifstr(i) $(Before) == $(!NetLibDECNet)
  3159.                 set !NetLibList = >( $(!NetLibList), $(!NetLibDECNet))
  3160.                 set !DECNetObjectID = $(After)
  3161.                 set !NetSelList = >( $(!NetSelList), *($(!NetworkSelList), 16))
  3162.                 set !NetSelList = >( $(!NetSelList), *($(!NetworkSelList), 17))
  3163.                 set !NetSelList = >( $(!NetSelList), *($(!NetworkSelList), 18))
  3164.             else-ifstr(i) $(Before) == $(!NetLibVines)
  3165.                 set !NetLibList = >( $(!NetLibList), $(!NetLibVines))
  3166.                 set !StreetName = $(After)
  3167.                 set !NetSelList = >( $(!NetSelList), *($(!NetworkSelList), 19))
  3168.                 set !NetSelList = >( $(!NetSelList), *($(!NetworkSelList), 20))
  3169.                 set !NetSelList = >( $(!NetSelList), *($(!NetworkSelList), 21))
  3170.             else
  3171.                 set !NetLibList = >( $(!NetLibList), $(Before))
  3172.                 set !NetworkSelList = >( $(!NetworkSelList), $(Before))
  3173.                 set !NetworkSelList = >( $(!NetworkSelList), $(!UserProvided))
  3174.                 set !NetworkSelList = >( $(!NetworkSelList), $(After)))
  3175.                 set !NetSelList = >( $(!NetworkSelList), $(Before))
  3176.                 set !NetSelList = >( $(!NetworkSelList), $(!UserProvided))
  3177.                 set !NetSelList = >( $(!NetworkSelList), $(After)))
  3178.             endif
  3179.         endif
  3180.     EndForListDo
  3181.     ifstr(i) $(!IntegratedSecurity) != "TRUE"
  3182.         set !NetworkSelList = >( $(!NetworkSelList), *($(!DefUserProvNet), 1))
  3183.         set !NetworkSelList = >( $(!NetworkSelList), *($(!DefUserProvNet), 2))
  3184.         set !NetworkSelList = >( $(!NetworkSelList), *($(!DefUserProvNet), 3))
  3185.     endif
  3186.     
  3187.     set !AllowExit = "YES"
  3188.     shell "" DoNetwork
  3189.     ifstr(i) $($R0) == "STATUS_USERQUIT"
  3190.         goto end_net_install
  3191.     else-ifstr(i) $($R0) == "STATUS_BACK"
  3192.         set Status = "STATUS_BACK"
  3193.         goto end_net_install
  3194.     endif
  3195.     shell "" DoNetLibPrompts $(!NetLibList), "TRUE"
  3196.     
  3197.     ifstr(i) $($R0) == "STATUS_BACK"
  3198.         set Status = $($R0)
  3199.         goto net_intsall
  3200.     else-ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  3201.         goto end_net_install
  3202.     endif
  3203.     set NewNetLibs = $($R1)
  3204.     set NewNetAddrs = $($R2)
  3205.     shell "" RegWriteListenOn $(OpenServerKey) $(NewNetLibs) $(NewNetAddrs)
  3206.     
  3207.     LibraryProcedure Result, $(!DLLSQL), RegClose $(OpenServerKey)
  3208.     
  3209.     set Status = "STATUS_SUCCESSFUL"
  3210. end_net_install =+
  3211.     Return $(Status)
  3212.     
  3213. [DoGetSecurityOptions]
  3214. scratch =+
  3215.     set Status = "STATUS_FAILED"
  3216.     read-syms SetSecError$(!STF_LANGUAGE)
  3217.     shell "" RegGetSecuritySupport
  3218.     set !DefRadio = $($R1)
  3219.     ifstr(i) $(!MultipleNetworkSupport) != ""
  3220.         ifstr(i) $(!DefRadio) == "2"
  3221.             set !DefRadio = "1"
  3222.         endif
  3223.     endif
  3224.     read-syms SecurityDlg$(!STF_LANGUAGE)
  3225.     LibraryProcedure DlgSec, $(!DLLSQL), SQLDlgDisplay $(STF_HWND),$(DlgTemplate),"",$(!SQLDlgNames),"MODAL",""
  3226.     LibraryProcedure Result, $(!DLLSQL), DlgSetEditText $(DlgSec),"EDIT1",$($R2)
  3227.     LibraryProcedure Result, $(!DLLSQL), DlgSetEditText $(DlgSec),"EDIT2",$($R3)
  3228.     ForListDo $(!DefSecurityTokens)
  3229.         LibraryProcedure Result, $(!DLLSQL), DlgAddCmbEntry $(DlgSec),"CALLCOMBO1",$($)
  3230.         LibraryProcedure Result, $(!DLLSQL), DlgAddCmbEntry $(DlgSec),"CALLCOMBO2",$($)
  3231.         LibraryProcedure Result, $(!DLLSQL), DlgAddCmbEntry $(DlgSec),"CALLCOMBO3",$($)
  3232.     EndForListDo
  3233.     LibraryProcedure Result, $(!DLLSQL), DlgSetCmbCurSel $(DlgSec),"CALLCOMBO1","BYEDIT",$($R5)
  3234.     LibraryProcedure Result, $(!DLLSQL), DlgSetCmbCurSel $(DlgSec),"CALLCOMBO2","BYEDIT",$($R6)
  3235.     LibraryProcedure Result, $(!DLLSQL), DlgSetCmbCurSel $(DlgSec),"CALLCOMBO3","BYEDIT",$($R7)
  3236.     shell "" DoSecurityComboChecking $(DlgSec),"CALLCOMBO1"
  3237.     shell "" DoSecurityComboChecking $(DlgSec),"CALLCOMBO2"
  3238.     shell "" DoSecurityComboChecking $(DlgSec),"CALLCOMBO3"
  3239.     set OldAccount = $($R2)
  3240.     set OldRadio = $(!DefRadio)
  3241.     ifstr(i) $($R4) == "1"
  3242.         LibraryProcedure Result, $(!DLLSQL), DlgCheckButton $(DlgSec),"UNIBUTTON1","TRUE"
  3243.     endif
  3244.     ifstr(i) $($R4) == "2"
  3245.         LibraryProcedure Result, $(!DLLSQL), DlgCheckButton $(DlgSec),"UNIBUTTON2","TRUE"
  3246.     endif
  3247.     ifstr(i) $($R4) == "3"
  3248.         LibraryProcedure Result, $(!DLLSQL), DlgCheckButton $(DlgSec),"UNIBUTTON1","TRUE"
  3249.         LibraryProcedure Result, $(!DLLSQL), DlgCheckButton $(DlgSec),"UNIBUTTON2","TRUE"
  3250.     endif
  3251.     ifstr(i) $($R8) == "1"
  3252.         LibraryProcedure Result, $(!DLLSQL), DlgCheckButton $(DlgSec),"UNIBUTTON3","TRUE"
  3253.     endif
  3254.     ifstr(i) $(!MultipleNetworkSupport) != ""
  3255.         LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(DlgSec),"DLGBUTTON2","FALSE"
  3256.     endif
  3257. sec =+
  3258.     LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(DlgSec),"TEXT1","TRUE"
  3259.     LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(DlgSec),"TEXT2","TRUE"
  3260.     LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(DlgSec),"TEXT3","TRUE"
  3261.     LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(DlgSec),"TEXT4","TRUE"
  3262.     LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(DlgSec),"TEXT5","TRUE"
  3263.     LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(DlgSec),"TEXT6","TRUE"
  3264.     LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(DlgSec),"EDIT1","TRUE"
  3265.     LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(DlgSec),"EDIT2","TRUE"
  3266.     LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(DlgSec),"UNIBUTTON3","TRUE"
  3267.     LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(DlgSec),"CALLCOMBO1","TRUE"
  3268.     LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(DlgSec),"CALLCOMBO2","TRUE"
  3269.     LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(DlgSec),"CALLCOMBO3","TRUE"
  3270.     LibraryProcedure DLGEVENT, $(!DLLSQL), WaitEvent
  3271.     ifstr(i) $(DLGEVENT) == "BACK"
  3272.         set Status = "STATUS_BACK"
  3273.         goto finish_sec
  3274.     else-ifstr(i) $(DLGEVENT) == "EXIT"
  3275.         shell "" QueryUserQuit $(!STF_LANGUAGE)
  3276.         ifstr(i) $($R1) == "OK"
  3277.             set Status = "STATUS_USERQUIT"
  3278.             goto finish_sec
  3279.         else
  3280.             goto sec
  3281.         endif
  3282.     else-ifstr(i) $(DLGEVENT) == "CONTINUE"
  3283.         set LoginMode = "0"
  3284.         set DefaultAccount = ""
  3285.         set DefaultDomain = ""
  3286.         set AuditLevel = "0"
  3287.         set SetHostname = "0"
  3288.         set Map1 = $(!DefSecMap1)
  3289.         set Map2 = $(!DefSecMap2)
  3290.         set Map3 = $(!DefSecMap3)
  3291.         LibraryProcedure ChkSucc, $(!DLLSQL), IsDlgBtnChecked $(DlgSec),"UNIBUTTON1"
  3292.         LibraryProcedure ChkFailed, $(!DLLSQL), IsDlgBtnChecked $(DlgSec),"UNIBUTTON2"
  3293.         LibraryProcedure Mode, $(!DLLSQL), IsDlgBtnChecked $(DlgSec),"DLGBUTTON1"
  3294.         ifstr(i) $(Mode) == "CHECKED"
  3295.             set OrgMode = "0"
  3296.         endif
  3297.         LibraryProcedure DefaultAccount, $(!DLLSQL), DlgGetEditText $(DlgSec),"EDIT1"
  3298.         LibraryProcedure DefaultDomain, $(!DLLSQL), DlgGetEditText $(DlgSec),"EDIT2"
  3299.         LibraryProcedure Map1, $(!DLLSQL), DlgGetCmbCurText $(DlgSec),"CALLCOMBO1",""
  3300.         LibraryProcedure Map2, $(!DLLSQL), DlgGetCmbCurText $(DlgSec),"CALLCOMBO2",""
  3301.         LibraryProcedure Map3, $(!DLLSQL), DlgGetCmbCurText $(DlgSec),"CALLCOMBO3",""
  3302.         shell "" DoGetTokenFromMap $(Map1)
  3303.         set Map1 = $($R0)
  3304.         shell "" DoGetTokenFromMap $(Map2)
  3305.         set Map2 = $($R0)
  3306.         shell "" DoGetTokenFromMap $(Map3)
  3307.         set Map3 = $($R0)
  3308.         ifstr(i) $(Map1) == $(Map2)
  3309.             ifstr(i) $(Map2) != ""
  3310.                 read-syms STR_DuplicateMap
  3311.                 shell "" MessageError
  3312.                 goto sec
  3313.             endif
  3314.         endif
  3315.         ifstr(i) $(Map1) == $(Map3)
  3316.             ifstr(i) $(Map3) != ""
  3317.                 read-syms STR_DuplicateMap
  3318.                 shell "" MessageError
  3319.                 goto sec
  3320.             endif
  3321.         endif
  3322.         ifstr(i) $(Map2) == $(Map3)
  3323.             ifstr(i) $(Map3) != ""
  3324.                 read-syms STR_DuplicateMap
  3325.                 shell "" MessageError
  3326.                 goto sec
  3327.             endif
  3328.         endif
  3329.         LibraryProcedure Mode, $(!DLLSQL), IsDlgBtnChecked $(DlgSec),"DLGBUTTON2"
  3330.         LibraryProcedure ChkSetHostname, $(!DLLSQL), IsDlgBtnChecked $(DlgSec),"UNIBUTTON3"
  3331.         LibraryProcedure Result, $(!DLLSQL), CloseDialog $(DlgSec)
  3332.         set DlgSec = ""
  3333.         
  3334.         ifstr(i) $(DefaultAccount) != $(OldAccount)
  3335.             shell "" DoAddLogin $(DefaultAccount)
  3336.             ifstr(i) $($R0) == "STATUS_BACK"
  3337.                 goto scratch
  3338.             else-ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  3339.                 goto finish_sec
  3340.             endif
  3341.         endif
  3342.         ifstr(i) $(Mode) == "CHECKED"
  3343.             set LoginMode = "1"
  3344.         else-ifstr(i) $(OrgMode) == "0"
  3345.             set LoginMode = "0"
  3346.         else
  3347.             set LoginMode = "2"
  3348.         endif
  3349.         ifstr(i) $(ChkSetHostname) == "CHECKED"
  3350.             set SetHostname = "1"
  3351.         else
  3352.             set SetHostname = "0"
  3353.         endif
  3354.         ifstr(i) $(ChkSucc) == "CHECKED"
  3355.             set-add AuditLevel = $(AuditLevel),1
  3356.         endif
  3357.         ifstr(i) $(ChkFailed) == "CHECKED"
  3358.             set-add AuditLevel = $(AuditLevel),2
  3359.         endif
  3360.         shell "" RegWriteSecuritySupport $(LoginMode),$(DefaultAccount),$(DefaultDomain),$(AuditLevel),$(Map1),$(Map2),$(Map3),$(SetHostname),"FORCE"
  3361.         set Status = "STATUS_SUCCESSFUL"
  3362.     else-ifstr(i) $(DLGEVENT) == "DLGBUTTON1"
  3363.         set !DefRadio = "1"
  3364.         goto sec
  3365.     else-ifstr(i) $(DLGEVENT) == "DLGBUTTON2"
  3366.         set !DefRadio = "2"
  3367.         goto sec
  3368.     else-ifstr(i) $(DLGEVENT) == "DLGBUTTON3"
  3369.         set !DefRadio = "3"
  3370.         goto sec
  3371.     else-ifstr(i) $(DLGEVENT) == "CALLCOMBOKILLFOCUS1"
  3372.         shell "" DoSecurityComboChecking $(DlgSec),"CALLCOMBO1"
  3373.         goto sec
  3374.     else-ifstr(i) $(DLGEVENT) == "CALLCOMBOKILLFOCUS2"
  3375.         shell "" DoSecurityComboChecking $(DlgSec),"CALLCOMBO2"
  3376.         goto sec
  3377.     else-ifstr(i) $(DLGEVENT) == "CALLCOMBOKILLFOCUS3"
  3378.         shell "" DoSecurityComboChecking $(DlgSec),"CALLCOMBO3"
  3379.         goto sec
  3380.     else
  3381.         goto sec
  3382.     endif
  3383. finish_sec =+
  3384.     ifstr(i) $(DlgSec) != ""
  3385.         LibraryProcedure Result, $(!DLLSQL), CloseDialog $(DlgSec)
  3386.     endif
  3387.     Return $(Status)
  3388.     
  3389. [DoGetLicensingMode]
  3390.     ifstr(i) $(!IniFilePath) != ""
  3391.         set DlgLis = ""
  3392.         set !LicszUsers = "0"
  3393.         LibraryProcedure LiscMode, $(!DLLSQL), GetPrivProfStr "License", "Mode", $(!IniFilePath)
  3394.         ifstr(i) $(LiscMode) == "1"
  3395.             LibraryProcedure !LicszUsers, $(!DLLSQL), GetPrivProfStr "License", "PerServerUsers", $(!IniFilePath)
  3396.             set !LicszMode = "PerServer"
  3397.         else
  3398.             set !LicszMode = "PerSeat"
  3399.         endif
  3400.     else
  3401.         ifstr(i) $(!WrkStaVersion) == "TRUE"
  3402.             read-syms LicenseWorkStaDlg$(!STF_LANGUAGE)
  3403.             LibraryProcedure DlgLis, $(!DLLSQL), SQLDlgDisplay $(STF_HWND),$(!DlgTemplate),"",$(!SQLDlgNames),"MODAL",""
  3404. wrk_lisc =+
  3405.             LibraryProcedure DLGEVENT, $(!DLLSQL), WaitEvent
  3406.             ifstr(i) $(DLGEVENT) == "EXIT"
  3407.                 shell "" QueryUserQuit $(!STF_LANGUAGE)
  3408.                 ifstr(i) $($R1) == "OK"
  3409.                     set Status = "STATUS_USERQUIT"
  3410.                     goto finish_lisc
  3411.                 else
  3412.                     goto wrk_lisc
  3413.                 endif
  3414.             else-ifstr(i) $(DLGEVENT) == "CONTINUE"
  3415.                 set Status = "STATUS_SUCCESSFUL"
  3416.                 goto finish_lisc
  3417.             endif
  3418.         endif
  3419.     endif
  3420.     StartWait
  3421.     ifstr(i) $(!RemoteComputer) != ""
  3422.         LibraryProcedure RemNTServer, $(!DLLSQL),IsNTServer "\\"$(!ComputerName)
  3423.     else
  3424.         set RemNTServer = ""
  3425.     endif
  3426.     LibraryProcedure NTServer, $(!DLLSQL),IsNTServer "\\."
  3427.     set LiscMode = "1"
  3428. doliscover=+
  3429.     set Status = "STATUS_FAILED"
  3430.     StartWait
  3431.     ifint $(!LocalBuildNumber) < $(!LicenseMin)
  3432.         install LoadLocalLicenseLibrary
  3433.     else
  3434.         ifstr(i) $(NTServer) != "TRUE"
  3435.             install LoadLocalLicenseLibrary
  3436.         else
  3437.             install LoadSystemLicenseLibrary
  3438.         endif
  3439.     endif
  3440.     EndWait
  3441.     ifstr(i) $(!DLLCPL) == ""
  3442.         goto finish_lisc
  3443.     endif
  3444. Lisc =+
  3445.     ifstr(i) $(!IniFilePath) == ""
  3446.         ifstr(i) $(!RemoteComputer) == ""
  3447.             LibraryProcedure Result, $(!DLLCPL),CPlSetup $(!LicFullSetup),$(STF_HWND),$(!RegLicenseSubKey),$(!LicenseFamilyName),$(!Setup_Title),$(!HelpSQLNTSetup),$(!LicGeneralHelp),$(!LicSeatHelp),$(!LicServerHelp)
  3448.         else
  3449.             LibraryProcedure Result, $(!DLLCPL),CPlSetup $(!LicRemoteFullSetup),$(!RemoteComputer),$(STF_HWND),$(!RegLicenseSubKey),$(!LicenseFamilyName),$(!Setup_Title),$(!HelpSQLNTSetup),$(!LicGeneralHelp),$(!LicSeatHelp),$(!LicServerHelp)
  3450.         endif
  3451.     else
  3452.         LibraryProcedure Result, $(!DLLCPL), CPlSetup, $(!LicUnattendedFullSetup),$(!RegLicenseSubKey),$(!LicenseFamilyName),$(!Setup_Title),$(!LicszMode),$(!LicszUsers)
  3453.     endif
  3454.     ifstr(i) $(Result) == "EXIT"
  3455.         shell "" QueryUserQuit $(!STF_LANGUAGE)
  3456.         ifstr(i) $($R1) == "OK"
  3457.             set Status = "STATUS_USERQUIT"
  3458.         else
  3459.             goto Lisc
  3460.         endif
  3461.     else-ifstr(i) $(Result) == "OK"
  3462.         set Status = "STATUS_SUCCESSFUL"
  3463.         set !LicenseWritten = "TRUE"
  3464.     endif
  3465.     install FreeLicenseLibrary
  3466. finish_lisc =+
  3467.     ifstr(i) $(DlgLis) != ""
  3468.         LibraryProcedure Result, $(!DLLSQL), CloseDialog $(DlgLis)
  3469.     endif
  3470.     StartWait
  3471.     ifint $(!BuildNumber) < $(!LicenseMin)
  3472.         shell "" DoLicenseNuke
  3473.     else
  3474.         ifstr(i) $(!RemoteComputer) != ""
  3475.             ifstr(i) $(RemNTServer) != "TRUE"
  3476.                 shell "" DoLicenseNuke
  3477.             endif
  3478.         else
  3479.             ifstr(i) $(NTServer) != "TRUE"
  3480.                 shell "" DoLicenseNuke
  3481.             endif
  3482.         endif
  3483.     endif
  3484.     EndWait
  3485.     Return $(Status)
  3486.     
  3487. [DoClientLicenseOk]
  3488.     set Moveon = "FALSE"
  3489.     StartWait
  3490.     ifstr(i) $($0) == "1"
  3491.         read-syms LicensingClientModeDlg$(!STF_LANGUAGE)
  3492.     else
  3493.         read-syms LicensingServerModeDlg$(!STF_LANGUAGE)
  3494.     endif
  3495.     set Status = "STATUS_FAILED"
  3496.     LibraryProcedure DlgCliLis, $(!DLLSQL), SQLDlgDisplay $(STF_HWND),$(!DlgTemplate),"",$(!SQLDlgNames),"MODAL",""
  3497.     LibraryProcedure Result, $(!DLLSQL), DlgCheckButton $(DlgCliLis),"DLGBUTTON1","FALSE","FOCUS"
  3498.     LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(DlgCliLis),"DLGBUTTON2","FALSE"
  3499.     EndWait
  3500. CliLisc =+
  3501.     LibraryProcedure DLGEVENT, $(!DLLSQL), WaitEvent
  3502.     ifstr(i) $(DLGEVENT) == "BACK"
  3503.         set Status = "STATUS_BACK"
  3504.         goto finish_clilisc
  3505.     else-ifstr(i) $(DLGEVENT) == "EXIT"
  3506.         shell "" QueryUserQuit $(!STF_LANGUAGE)
  3507.         ifstr(i) $($R1) == "OK"
  3508.             set Status = "STATUS_USERQUIT"
  3509.             goto finish_clilisc
  3510.         else
  3511.             goto CliLisc
  3512.         endif
  3513.     else-ifstr(i) $(DLGEVENT) == "DLGBUTTON1"
  3514.         LibraryProcedure ClChecked, $(!DLLSQL), IsDlgBtnChecked $(DlgCliLis),"DLGBUTTON1"
  3515.         ifstr(i) $(ClChecked) == "CHECKED"
  3516.             LibraryProcedure Result, $(!DLLSQL), DlgCheckButton $(DlgCliLis),"DLGBUTTON1","FALSE","FOCUS"
  3517.             LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(DlgCliLis),"DLGBUTTON2","FALSE"
  3518.             set Moveon = "FALSE"
  3519.         else
  3520.             LibraryProcedure Result, $(!DLLSQL), DlgCheckButton $(DlgCliLis),"DLGBUTTON1","TRUE","FOCUS"
  3521.             LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(DlgCliLis),"DLGBUTTON2","TRUE"
  3522.             set Moveon = "TRUE"
  3523.         endif
  3524.         goto CliLisc
  3525.     else-ifstr(i) $(DLGEVENT) == "DLGBUTTON2"
  3526.         set Status = "STATUS_SUCCESSFUL"
  3527.     else-ifstr(i) $(DLGEVENT) == "CONTINUE"
  3528.         ifstr(i) $(Moveon) != "TRUE"
  3529.             goto CliLisc
  3530.         endif
  3531.         set Status = "STATUS_SUCCESSFUL"
  3532.     endif
  3533. finish_clilisc =+
  3534.     ifstr(i) $(DlgCliLis) != ""
  3535.         LibraryProcedure Result, $(!DLLSQL), CloseDialog $(DlgCliLis)
  3536.     endif
  3537.     Return $(Status)
  3538.     
  3539. [DoGetUserID]
  3540.     ifstr(i) $(!IniFilePath) != ""
  3541.         LibraryProcedure ChkSucc, $(!DLLSQL), GetPrivProfStr "LogonAccount", "LocalSystem", $(!IniFilePath)
  3542.         ifstr(i) $(ChkSucc) != "CHECKED"
  3543.             LibraryProcedure !UserName, $(!DLLSQL), GetPrivProfStr "LogonAccount", "UserName", $(!IniFilePath)
  3544.             LibraryProcedure !UserPassword, $(!DLLSQL), GetPrivProfStr "LogonAccount", "UserPassword", $(!IniFilePath)
  3545.             set TestCreate = TRUE
  3546.         else
  3547.             set !UserName = ""
  3548.             set !UserPassword = ""
  3549.             set TestCreate = FALSE
  3550.         endif
  3551.         set Status = "STATUS_SUCCESSFUL"
  3552.         goto endDoGetUserID
  3553.     endif
  3554.     set Status = "STATUS_FAILED"
  3555.     set !UserName = ""
  3556.     set !UserPassword = ""
  3557.     set TestCreate = FALSE
  3558.     LibraryProcedure !UserName $(!DLLSQL),GetAccountName "USER"
  3559. getuser_start =+
  3560.     read-syms SetUserIDError$(!STF_LANGUAGE)
  3561.     read-syms UserAccountDlg$(!STF_LANGUAGE)
  3562.     LibraryProcedure DlgUserID, $(!DLLSQL), SQLDlgDisplay $(STF_HWND),$(DlgTemplate),"",$(!SQLDlgNames),"MODAL",""
  3563.     LibraryProcedure Result, $(!DLLSQL), DlgCheckButton $(DlgUserID),"DLGBUTTON1","DLGBUTTON1","DLGBUTTON2"
  3564.     LibraryProcedure Result, $(!DLLSQL), DlgSetEditText $(DlgUserID),"EDIT1",$(!UserName)
  3565.     LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(DlgUserID),"TEXT1","TRUE"
  3566.     LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(DlgUserID),"EDIT1","TRUE"
  3567.     LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(DlgUserID),"TEXT2","TRUE"
  3568.     LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(DlgUserID),"EDIT2","TRUE"
  3569.     LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(DlgUserID),"TEXT3","TRUE"
  3570.     LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(DlgUserID),"EDIT3","TRUE"
  3571.     set Status = "STATUS_SUCCESSFUL"
  3572. moreuser =+
  3573.     LibraryProcedure DLGEVENT, $(!DLLSQL), WaitEvent
  3574.     ifstr(i) $(DLGEVENT) == "BACK"
  3575.         set Status = "STATUS_BACK"
  3576.         goto finish_userid
  3577.     else-ifstr(i) $(DLGEVENT) == "DLGBUTTON2"
  3578.         LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(DlgUserID),"TEXT1","FALSE"
  3579.         LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(DlgUserID),"EDIT1","FALSE"
  3580.         LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(DlgUserID),"TEXT2","FALSE"
  3581.         LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(DlgUserID),"EDIT2","FALSE"
  3582.         LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(DlgUserID),"TEXT3","FALSE"
  3583.         LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(DlgUserID),"EDIT3","FALSE"
  3584.         goto moreuser
  3585.     else-ifstr(i) $(DLGEVENT) == "DLGBUTTON1"
  3586.         LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(DlgUserID),"TEXT1","TRUE"
  3587.         LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(DlgUserID),"EDIT1","TRUE"
  3588.         LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(DlgUserID),"TEXT2","TRUE"
  3589.         LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(DlgUserID),"EDIT2","TRUE"
  3590.         LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(DlgUserID),"TEXT3","TRUE"
  3591.         LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(DlgUserID),"EDIT3","TRUE"
  3592.         goto moreuser
  3593.     else-ifstr(i) $(DLGEVENT) == "EXIT"
  3594.         shell "" QueryUserQuit $(!STF_LANGUAGE)
  3595.         ifstr(i) $($R1) == "OK"
  3596.             set Status = "STATUS_USERQUIT"
  3597.             ifstr(i) $(DlgUserID) != ""
  3598.                 LibraryProcedure Result, $(!DLLSQL), CloseDialog $(DlgUserID)
  3599.                 set DlgUserID = ""
  3600.             endif
  3601.             goto finish_userid
  3602.         else
  3603.             goto moreuser
  3604.         endif
  3605.     else-ifstr(i) $(DLGEVENT) == "CONTINUE"
  3606.         LibraryProcedure !UserName, $(!DLLSQL), DlgGetEditText $(DlgUserID),"EDIT1"
  3607.         LibraryProcedure !UserPassword, $(!DLLSQL), DlgGetEditText $(DlgUserID),"EDIT2"
  3608.         LibraryProcedure ChkSucc, $(!DLLSQL), IsDlgBtnChecked $(DlgUserID),"DLGBUTTON2"
  3609.         ifstr(i) $(ChkSucc) != "CHECKED"
  3610.             ifstr(i) $(!UserName) != ""
  3611.                 LibraryProcedure PassConfirm, $(!DLLSQL), DlgGetEditText $(DlgUserID),"EDIT3"
  3612.                 ifstr(i) $(!UserPassword) != $(PassConfirm)
  3613.                     read-syms PasswordsDontMatch$(!STF_LANGUAGE)
  3614.                     shell "" MessageError
  3615.                     goto moreuser
  3616.                 endif
  3617.             endif
  3618.         endif
  3619.         ifstr(i) $(DlgUserID) != ""
  3620.             LibraryProcedure Result, $(!DLLSQL), CloseDialog $(DlgUserID)
  3621.             EndWait
  3622.             set DlgUserID = ""
  3623.         endif
  3624.         ifstr(i) $(ChkSucc) == "CHECKED"
  3625.             set !UserName = ""
  3626.             set !UserPassword = ""
  3627.         else-ifstr(i) $(!UserName) == ""
  3628.             set !UserPassword = ""
  3629.         else
  3630.             read-syms VerifyAcctDlg$(!STF_LANGUAGE)
  3631.             LibraryProcedure DlgVerify, $(!DLLSQL), SQLDlgDisplay $(STF_HWND),$(DlgTemplate),"",$(!SQLDlgNames),"MODAL",""
  3632.             ifstr(i) $(!RemoteComputer) != ""
  3633.                 set LocalDomMach = "\\"$(!RemoteComputer)
  3634.             else
  3635.                 set LocalDomMach = ""
  3636.             endif
  3637.             LibraryProcedure Verified, $(!DLLSQL),VerifyDomainAccount, $(LocalDomMach),$(!UserName),
  3638.             ifstr(i) $(Verified) == ""
  3639.                 shell "" CreateTestService
  3640.                 set TestCreate = "TRUE"
  3641.                 LibraryProcedure Result, $(!DLLSQL), CloseDialog $(DlgVerify)
  3642.                 ifstr(i) $($R1) == "CANNOT_LOGON_SERVICE"
  3643.                     set Status = "STATUS_FAILED"
  3644.                     read-syms SetUserIDError$(!STF_LANGUAGE)
  3645.                     LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)
  3646.                     shell "" MessageError
  3647.                     goto getuser_start
  3648.                 else
  3649.                     set Status = "STATUS_SUCCESSFUL"
  3650.                 endif
  3651.             else
  3652.                 LibraryProcedure Result, $(!DLLSQL), CloseDialog $(DlgVerify)
  3653.                 set Status = "STATUS_FAILED"
  3654.                 read-syms SetUserIDError$(!STF_LANGUAGE)
  3655.                 LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)
  3656.                 shell "" MessageError
  3657.                 goto getuser_start
  3658.             endif
  3659.         endif
  3660.     endif
  3661. finish_userid =+
  3662.     ifstr(i) $(DlgUserID) != ""
  3663.         LibraryProcedure Result, $(!DLLSQL), CloseDialog $(DlgUserID)
  3664.         set DlgUserID = ""
  3665.         EndWait
  3666.     endif
  3667. endDoGetUserID =+
  3668.     Return $(Status) $(TestCreate)
  3669.     
  3670. [CreateTestService]
  3671.     set Status = "STATUS_SUCCESSFUL"
  3672.     set pollLoop = "1"
  3673.     set ErrorNumber = ""
  3674.     ifstr(i) $(!RemoteComputer) == ""
  3675.         set NewSQLPath = $(!SQLPath)
  3676.     else
  3677.         LibraryProcedure Temp, $(!DLLSQL), StrBeforeAndAfter $(!SQLPath),"AFTER",":"
  3678.         LibraryProcedure NewSQLPath, $(!DLLSQL), AppendToString $(!LogicalSQLDrive),$(Temp)
  3679.     endif
  3680.     LibraryProcedure Result, $(!DLLSQL), DoServiceOp "\\"$(!ComputerName),"SERVICE_REMOVE",$(!SQLServerService) ,"",""
  3681. pollTestCreate =+
  3682.     LibraryProcedure Result, $(!DLLSQL), DoServiceOp "\\"$(!ComputerName),"SERVICE_CREATE",$(!SQLServerService) ,$(NewSQLPath)"\"$(!Binaries)"\"$(!SQLServer),$(!UserName),$(!UserPassword),"",$(StartType)
  3683.     ifstr(i) $(Result) != ""
  3684.         ifstr(i) $(Result) == "CANNOT_LOGON_SERVICE"
  3685.             set ErrorNumber = $(Result)
  3686.             goto service_end
  3687.         endif
  3688.         ifint $(pollLoop) < "5"
  3689.             set-add pollLoop = $(pollLoop),1
  3690.             goto pollTestCreate
  3691.         endif
  3692.         LibraryProcedure Err, $(!DLLSQL), GetLastSetupError
  3693.         set ErrorNumber = " #SCM2 - "$(Err)
  3694.         set Status = "STATUS_FAILED"
  3695.     else
  3696.         shell "" StartService $(!SQLServerService) , "TestCreate"
  3697.         ifstr(i) $($R1) == "CANNOT_LOGON_SERVICE"
  3698.             set ErrorNumber  = $($R1)
  3699.             goto service_end
  3700.         endif
  3701.         shell "" StopService $(!SQLServerService)
  3702.     endif
  3703. service_end =+
  3704.     LibraryProcedure Result, $(!DLLSQL), DoServiceOp "\\"$(!ComputerName),"SERVICE_REMOVE",$(!SQLServerService) ,"",""
  3705.     Return $(Status) $(ErrorNumber)
  3706.     
  3707. [DoGetTokenFromMap]
  3708.     set Ret = $($0)
  3709.     ifstr(i) $($0) == $(!SecStrNotUsed)
  3710.         set Ret = ""
  3711.     endif
  3712.     ifstr(i) $($0) == $(!SecStrDomSep)
  3713.         set Ret = $(!SecTokDomainSep)
  3714.     endif
  3715.     ifstr(i) $($0) == $(!SecStrSpace)
  3716.         set Ret = $(!SecTokSpace)
  3717.     endif
  3718.     Return $(Ret)
  3719.         
  3720. [DoSecurityComboChecking]
  3721.     set Status = "STATUS_SUCCESSFUL"
  3722.     LibraryProcedure Text, $(!DLLSQL), DlgGetCmbCurText $($0),$($1),""
  3723.     ifstr(i) $(Text) == ""
  3724.         LibraryProcedure Result, $(!DLLSQL), DlgSetCmbCurSel $($0),$($1),"BYEDIT",$(!SecStrNotUsed)
  3725.     else-ifstr(i) $(Text) == $(!SecTokDomainSep)
  3726.         LibraryProcedure Result, $(!DLLSQL), DlgSetCmbCurSel $($0),$($1),"BYEDIT",$(!SecStrDomSep)
  3727.     else-ifstr(i) $(Text) == $(!SecTokSpace)
  3728.         LibraryProcedure Result, $(!DLLSQL), DlgSetCmbCurSel $($0),$($1),"BYEDIT",$(!SecStrSpace)
  3729.     endif
  3730.     Return $(Status)
  3731.         
  3732. [DoAddLogin]
  3733.     set Status = "STATUS_FAILED"
  3734.     shell "" DoGetSAPassword
  3735.     ifstr(i) $($R0) == "STATUS_BACK"
  3736.         set Status = "STATUS_BACK"
  3737.         goto end_addlogin
  3738.     else-ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  3739.         goto end_addlogin
  3740.     endif
  3741.     shell "" StartService $(!SQLServerService)
  3742.     ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  3743.         goto end_addlogin
  3744.     endif
  3745.     StartWait
  3746.     LibraryProcedure Result, $(!DLLSQL), SQLLogin $(!LoginSleepPeriod),$(!LoginSleepRetrys),$(!ServerName),$(!SALogin),$(!SAPassword)
  3747.     ifstr(i) $(Result) == "NO_SERVER"
  3748.         read-syms NoLoginToSQLServer$(!STF_LANGUAGE)
  3749.         LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)
  3750.         goto end_addlogin
  3751.     endif
  3752.     StartWait
  3753.     set CheckAddLogin = $(!CheckLogin)"'"$($0)"'"
  3754.     shell "" ExecNReturnSQLCmd $(CheckAddLogin),"NTBSTRINGBIND"
  3755.     ifstr(i) $($R0) == "STATUS_SUCCESSFUL"
  3756.         ifstr(i) $($R1) == $($0)
  3757.             set Status = "STATUS_SUCCESSFUL"
  3758.             goto end_addlogin
  3759.         endif
  3760.     endif
  3761.     LibraryProcedure Result, $(!DLLSQL), SQLExecute $(!SQLAddLogin)"'"$($0)"',NULL,'master'"
  3762.     ifstr(i) $(Result) == "BAD_SQL_EXEC"
  3763.         read-syms SQLExecError$(!STF_LANGUAGE)
  3764.         LibraryProcedure !AddlText, $(!DLLSQL), SQLGetErrorMsg
  3765.         LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)
  3766.         goto end_addlogin
  3767.     endif
  3768.     set Status = "STATUS_SUCCESSFUL"
  3769. end_addlogin =+
  3770.     LibraryProcedure Result, $(!DLLSQL), SQLLogout
  3771.     EndWait
  3772.     Return $(Status)
  3773.     
  3774. [DoDelete95Key]
  3775.     
  3776.     ifstr(i) $($1) == "DELOLD"
  3777.         ifstr(i) $(!InstallType) == "2"
  3778.             ifstr(i) $(!SQL95Keys) == "TRUE"
  3779.                 goto enddelete
  3780.             endif
  3781.         endif
  3782.         set tRegRoot = $(!RegOldSQLServer)
  3783.         set tRegRootServer = $(!RegOldSQLServerServer)
  3784.         set tRegService = $(!SQLOldServerService)
  3785.         set tRegClient = $(!RegOldSQLClient)
  3786.     else
  3787.         set tRegRoot = $(!RegSQLServer)
  3788.         set tRegRootServer = $(!RegSQLServerServer)
  3789.         set tRegService = $(!SQLServerService)
  3790.         set tRegClient = $(!RegSQLClient)
  3791.     endif
  3792.     
  3793.     
  3794.     LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$($0),"UNIDELETE",$(tRegRootServer),$(!RegSQLServerVer)
  3795.     LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$($0),"UNIDELETE",$(tRegRootServer),$(!RegSQLSvrParam)
  3796.     LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$($0),"UNIDELETE",$(tRegRootServer),$(!RegRPCNetLib)
  3797.     LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$($0),"UNIDELETE",$(tRegRoot),$(!RegSQLServerSvr)
  3798.     LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$($0),"UNIDELETE",$(!RegEventAppLog),$(tRegService)
  3799.     
  3800.       ifstr(i) $($1) != "DELOLD"
  3801.     LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$($0),"UNIDELETE",$(!RegEventAppLog),$(!SQLSchedulerService)
  3802.     LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$(!ComputerName),"UNIDELETE",$(!RegEventAppLog),$(!SQLCtrs)
  3803. else
  3804.     LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$(!ComputerName),"UNIDELETE",$(!RegEventAppLog),$(!OldSQLCtrs)
  3805. endif
  3806.     
  3807.     LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$($0),"UNIDELETE",$(tRegRoot),$(!RegSQLSetupKey)
  3808.     LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$($0),"UNIDELETE",$(tRegRoot),$(!RegSQLAdmin)
  3809.     LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$($0),"UNIDELETE",$(tRegRoot),$(!RegStarFighter)
  3810.     LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$($0),"UNIDELETE",$(tRegRoot),$(!RegValSQLReplication)"\"$(!RegValReplDir)
  3811.     LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$($0),"UNIDELETE",$(tRegRoot),$(!RegValSQLReplication)
  3812.     LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$($0),"UNIDELETE",$(tRegRoot),$(!SQLSchedulerService)"\"$(!SQLSchedulerSubService)
  3813.     LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$($0),"UNIDELETE",$(tRegRoot),$(!SQLSchedulerService)
  3814.     LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$($0),"UNIDELETE",$(tRegRoot),$(!RegSQLOM)
  3815.     LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$($0),"UNIDELETE",$(tRegRoot),$(!RegISQLW)
  3816.     LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$($0),"UNIDELETE",$(tRegRoot),$(!RegSecMan)
  3817.     LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$($0),"UNIDELETE",$(tRegRoot),$(!RegSQLSvcMgr)
  3818.     LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$($0),"UNIDELETE",$(tRegRoot),$(!SQLMonitorService)"\"$(!RegSQLSvrParam)
  3819.     LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$($0),"UNIDELETE",$(tRegRoot),$(!SQLMonitorService)
  3820.     LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$($0),"UNIDELETE",$(tRegClient),$(!RegSQLDBLib)
  3821.     LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$($0),"UNIDELETE",$(tRegClient),$(!RegSQLConnectTo)
  3822.     LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$($0),"UNIDELETE",$(tRegClient),$(!RegMonitor)
  3823.     LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$($0),"UNIDELETE",$(tRegClient),$(!RegSQLPrefServers)
  3824.     LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$($0),"UNIDELETE",$(tRegRoot),$(!RegClient)
  3825.     LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$($0),"ENUMDELETE",$(tRegRoot),""
  3826.     LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$($0),"UNIDELETE",$(!RegSWMS),$(tRegService)
  3827. enddelete =+
  3828.     return
  3829.         
  3830. [DoNuke]
  3831.     set Status = "STATUS_FAILED"
  3832.     read-syms NukeError$(!STF_LANGUAGE)
  3833.     read-syms NukeDlg$(!STF_LANGUAGE)
  3834.     LibraryProcedure DlgNuke, $(!DLLSQL), SQLDlgDisplay $(STF_HWND),$(DlgTemplate),"",$(!SQLDlgNames),"MODAL",""
  3835. nuke =+
  3836.     LibraryProcedure DLGEVENT, $(!DLLSQL), WaitEvent
  3837.     ifstr(i) $(DLGEVENT) == "BACK"
  3838.         set Status = "STATUS_BACK"
  3839.         goto finish_nuke
  3840.     else-ifstr(i) $(DLGEVENT) == "EXIT"
  3841.         shell "" QueryUserQuit $(!STF_LANGUAGE)
  3842.         ifstr(i) $($R1) == "OK"
  3843.             set Status = "STATUS_USERQUIT"
  3844.             goto finish_nuke
  3845.         else
  3846.             goto nuke
  3847.         endif
  3848.     else-ifstr(i) $(DLGEVENT) == "CONTINUE"
  3849.         StartWait
  3850.         shell "" StopService $(!SQLMonitorService)
  3851.         shell "" StopService $(!SQLSchedulerService)
  3852.         shell "" StopService $(!SQLOldSchedulerService)
  3853.         shell "" StopService $(!SQLServerService)
  3854.         shell "" StopService $(!MSDTCService)
  3855.         
  3856.         shell "" DoPerfmonNuke "\\"$(!ComputerName)
  3857.         
  3858.         shell "" DoGroupOrderNuke "\\"$(!ComputerName)
  3859.  
  3860.         LibraryProcedure Results, $(!DLLSQL), DoOleRegistration $(!SQLPath)"\"$(!Binaries)"\"$(!SQLOle32),"UNREGISTER"
  3861.         LibraryProcedure Results, $(!DLLSQL), DoOleRegistration $(!SQLPath)"\"$(!Binaries)"\"$(!ODSOle32),"UNREGISTER"
  3862.         
  3863.         LibraryProcedure Result, $(!DLLSQL), DoServiceOp "\\"$(!ComputerName),"SERVICE_REMOVE",$(!SQLServerService),"",""
  3864.         LibraryProcedure Result, $(!DLLSQL), DoServiceOp "\\"$(!ComputerName),"SERVICE_REMOVE",$(!SQLSchedulerService),"",""
  3865.         LibraryProcedure Result, $(!DLLSQL), DoServiceOp "\\"$(!ComputerName),"SERVICE_REMOVE",$(!MSDTCService),"",""
  3866.  
  3867.         LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$(!ComputerName),"UNIDELETE",$(!RegSQLServerServer),$(!RegSQLServerVer)
  3868.         LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$(!ComputerName),"UNIDELETE",$(!RegSQLServerServer),$(!RegSQLSvrParam)
  3869.         LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$(!ComputerName),"UNIDELETE",$(!RegSQLServerServer),$(!RegRPCNetLib)
  3870.         LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$(!ComputerName),"UNIDELETE",$(!RegSQLServer),$(!RegSQLServerSvr)
  3871.         LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$(!ComputerName),"UNIDELETE",$(!RegSWMS),$(!SQLServerService)
  3872.         LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$(!ComputerName),"UNIDELETE",$(!RegEventAppLog),$(!SQLServerService)
  3873.         LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$(!ComputerName),"UNIDELETE",$(!RegEventAppLog),$(!SQLSchedulerService)
  3874.         LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$(!ComputerName),"UNIDELETE",$(!RegEventAppLog),$(!SQLCtrs)
  3875.         LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$(!ComputerName),"UNIDELETE",$(!RegSQLServer),$(!RegSQLSetupKey)
  3876.         LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$(!ComputerName),"UNIDELETE",$(!RegSQLServer),$(!RegSQLAdmin)
  3877.         LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$(!ComputerName),"UNIDELETE",$(!RegSQLServer),$(!RegStarFighter)
  3878.         LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$(!ComputerName),"UNIDELETE",$(!RegSQLServer),$(!RegValSQLReplication)"\"$(!RegValReplDir)
  3879.         LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$(!ComputerName),"UNIDELETE",$(!RegSQLServer),$(!RegValSQLReplication)
  3880.         LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$(!ComputerName),"UNIDELETE",$(!RegSQLServer),$(!SQLSchedulerService)"\"$(!SQLSchedulerSubService)
  3881.         LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$(!ComputerName),"UNIDELETE",$(!RegSQLServer),$(!SQLSchedulerService)
  3882.         LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$(!ComputerName),"UNIDELETE",$(!RegSQLServer),$(!RegSQLOM)
  3883.         LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$(!ComputerName),"UNIDELETE",$(!RegSQLServer),$(!RegISQLW)
  3884.         LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$(!ComputerName),"UNIDELETE",$(!RegSQLServer),$(!RegSecMan)
  3885.         LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$(!ComputerName),"UNIDELETE",$(!RegSQLServer),$(!RegSQLSvcMgr)
  3886.  
  3887.  
  3888.         LibraryProcedure ResultKey, $(!DLLSQL), RegMakeKey "\\"$(!ComputerName),"Software\Microsoft\Query\2.0","Data Sources","","HKEY_CURRENT_USER"
  3889.         LibraryProcedure Result, $(!DLLSQL), RegDelValue $(ResultKey),"Local Server"
  3890.         LibraryProcedure Result, $(!DLLSQL), RegClose $(ResultKey)
  3891.  
  3892.  
  3893.         LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$(!ComputerName),"UNIDELETE","SOFTWARE\ODBC\ODBC.INI","Local Server"
  3894.  
  3895.         LibraryProcedure ResultKey, $(!DLLSQL), RegMakeKey "\\"$(!ComputerName),"SOFTWARE\ODBC\ODBC.INI","ODBC Data Sources","",""
  3896.         LibraryProcedure Result, $(!DLLSQL), RegDelValue $(ResultKey),"Local Server"
  3897.         LibraryProcedure Result, $(!DLLSQL), RegClose $(ResultKey)
  3898.  
  3899.         shell "" RegUpdateTCPIPSupport "FALSE"
  3900.         
  3901.         shell "" DoLicenseNuke
  3902.  
  3903.         LibraryProcedure SNMPInstalled, $(!DLLSQL), GetServiceState "\\"$(!ComputerName), $(!SNMPService)
  3904.         ifstr(i) $(SNMPInstalled) != "SERVICE_NOT_EXIST"
  3905.             LibraryProcedure OpenSQLSNMPKey, $(!DLLSQL), RegOpen "\\"$(!ComputerName), $(!RegSQLServer)"\"$(!RegSQLSNMP)
  3906.             ifstr(i) OpenSQLSNMPKey != "KEY_ERROR"
  3907.                 LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$(!ComputerName),"UNIDELETE",$(!RegSQLServer),$(!RegSQLSNMP)"\"$(!RegCurrentVer)
  3908.                 LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$(!ComputerName),"UNIDELETE",$(!RegSQLServer),$(!RegSQLSNMP)
  3909.                 shell "" DoNukeSQLSNMPAgent
  3910.             endif
  3911.         endif
  3912.         
  3913.         LibraryProcedure Result, $(!DLLSQL), IsDlgBtnChecked $(DlgNuke),"UNIBUTTON1"
  3914.         ifstr(i) $(Result) == "CHECKED"
  3915.             ifstr(i) $(!DefSQLPath) != "\\"
  3916.                 ifstr(i)  $(!DefSQLPath) != ""
  3917.                     LibraryProcedure Result, $(!DLLSQL), Delnode "TREE_DELETE",$(!DefSQLPath)
  3918.                 else
  3919.                     read-syms DontDeleteRoot$(!STF_LANGUAGE)
  3920.                     shell "" MessageError
  3921.                 endif
  3922.             else
  3923.                 read-syms DontDeleteRoot$(!STF_LANGUAGE)
  3924.                 shell "" MessageError
  3925.             endif
  3926.         endif
  3927.         
  3928.         EndWait
  3929.         
  3930.         
  3931.         shell "" RegDeleteSystemPaths "\\"$(!ComputerName),$(!RegSystemPaths), ""
  3932.         ifstr(i) $(!RemoteComputer) == ""
  3933.             set !ProgramTitle =  $(!SQLProgmanGrpName)
  3934.             install NukeSQLProgmanItems
  3935.         endif
  3936.  
  3937.         set Status = "STATUS_SUCCESSFUL"
  3938.     endif
  3939.  
  3940. finish_nuke =+
  3941.     LibraryProcedure Result, $(!DLLSQL), CloseDialog $(DlgNuke)
  3942.     EndWait
  3943.     Return $(Status)
  3944.     
  3945. [DoLicenseNuke]
  3946.     LibraryProcedure OpenLicenseKey, $(!DLLSQL), RegOpen "\\"$(!ComputerName),$(!RegSQLLicInfoKey)
  3947.     ifstr(i) $(OpenLicenseKey) != "KEY_ERROR"
  3948.         LibraryProcedure Result, $(!DLLSQL), RegDelValue $(OpenLicenseKey),$(!RegValLicMode)
  3949.         LibraryProcedure Result, $(!DLLSQL), RegDelValue $(OpenLicenseKey),$(!RegValLicCon)
  3950.         LibraryProcedure Result, $(!DLLSQL), RegDelValue $(OpenLicenseKey),$(!RegValLicFlip)
  3951.         LibraryProcedure Result, $(!DLLSQL), RegDelValue $(OpenLicenseKey),$(!RegValLicDspName)
  3952.         LibraryProcedure Result, $(!DLLSQL), RegDelValue $(OpenLicenseKey),$(!RegValLicFDspName)
  3953.         LibraryProcedure Result, $(!DLLSQL), RegClose $(OpenLicenseKey)
  3954.     endif
  3955.     LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$(!ComputerName),"UNIDELETE",$(!RegLicInfoKey),$(!RegLicenseSubKey)
  3956.     Return
  3957.     
  3958. [DoLicense60Nuke]
  3959.     LibraryProcedure OpenLicenseKey, $(!DLLSQL), RegOpen "\\"$(!ComputerName),$(!RegSQL60LicInfoKey)
  3960.     ifstr(i) $(OpenLicenseKey) != "KEY_ERROR"
  3961.         LibraryProcedure Result, $(!DLLSQL), RegDelValue $(OpenLicenseKey),$(!RegValLicMode)
  3962.         LibraryProcedure Result, $(!DLLSQL), RegDelValue $(OpenLicenseKey),$(!RegValLicCon)
  3963.         LibraryProcedure Result, $(!DLLSQL), RegDelValue $(OpenLicenseKey),$(!RegValLicFlip)
  3964.         LibraryProcedure Result, $(!DLLSQL), RegDelValue $(OpenLicenseKey),$(!RegValLicDspName)
  3965.         LibraryProcedure Result, $(!DLLSQL), RegDelValue $(OpenLicenseKey),$(!RegValLicFDspName)
  3966.         LibraryProcedure Result, $(!DLLSQL), RegClose $(OpenLicenseKey)
  3967.     endif
  3968.     LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$(!ComputerName),"UNIDELETE",$(!RegLicInfoKey),$(!RegLic60SubKey)
  3969.     Return
  3970.  
  3971. [DoClientNuke]
  3972.     StartWait
  3973.     ifstr(i) $(!STF_OS) == "95"
  3974.         set Connect = ""
  3975.     else
  3976.         set Connect = "\\"$(!ComputerName)
  3977.     endif
  3978.     set Status = "STATUS_FAILED"
  3979.     LibraryProcedure Result, $(!DLLSQL), RegEnumDelete $(Connect),"UNIDELETE",$(!RegSQLServer),$(!RegSQLClientSetupKey)
  3980.     LibraryProcedure Result, $(!DLLSQL), RegEnumDelete $(Connect),"UNIDELETE",$(!RegSQLServer),$(!RegSQLAdmin)
  3981.     LibraryProcedure Result, $(!DLLSQL), RegEnumDelete $(Connect),"UNIDELETE",$(!RegSQLServer),$(!RegStarFighter)
  3982.     LibraryProcedure Result, $(!DLLSQL), RegEnumDelete $(Connect),"UNIDELETE",$(!RegSQLServer),$(!RegValSQLReplication)"\"$(!RegValReplDir)
  3983.     LibraryProcedure Result, $(!DLLSQL), RegEnumDelete $(Connect),"UNIDELETE",$(!RegSQLServer),$(!RegValSQLReplication)
  3984.     LibraryProcedure Result, $(!DLLSQL), RegEnumDelete $(Connect),"UNIDELETE",$(!RegSQLServer),$(!RegSQLOM)
  3985.     LibraryProcedure Result, $(!DLLSQL), RegEnumDelete $(Connect),"UNIDELETE",$(!RegSQLServer),$(!RegISQLW)
  3986.     LibraryProcedure Result, $(!DLLSQL), RegEnumDelete $(Connect),"UNIDELETE",$(!RegSQLServer),$(!RegSecMan)
  3987.     ifstr(i) $(!DefSQLPath) != "\\"
  3988.         ifstr(i)  $(!DefSQLPath) != ""
  3989.             LibraryProcedure Result, $(!DLLSQL), Delnode "TREE_DELETE",$(!DefSQLPath)
  3990.         else
  3991.             read-syms DontDeleteRoot$(!STF_LANGUAGE)
  3992.             shell "" MessageError
  3993.         endif
  3994.     else
  3995.         read-syms DontDeleteRoot$(!STF_LANGUAGE)
  3996.         shell "" MessageError
  3997.     endif
  3998.     install NukeClientProgmanItems
  3999.     LibraryProcedure Result, $(!DLLSQL), SetNewPath $(!SQLPath)"\"$(!Binaries),"TRUE","TRUE"
  4000.     ifstr(i) $(Result) == "READONLY"
  4001.         read-syms ReadOnlyAutoexec$(!STF_LANGUAGE)
  4002.         goto finish_clinuke
  4003.     endif
  4004.     LibraryProcedure Result, $(!DLLSQL), SetNewPath $(!SQLPath)"\"$(!Binaries),"FALSE","TRUE"
  4005.     ifstr(i) $(Result) == "READONLY"
  4006.         read-syms ReadOnlyAutoexec$(!STF_LANGUAGE)
  4007.         goto finish_clinuke
  4008.     endif
  4009.     set Status = "STATUS_SUCCESSFUL"
  4010. finish_clinuke =+
  4011.     EndWait
  4012.     Return $(Status)
  4013.         
  4014. [DoLicense]
  4015.     ifstr(i) $(!IniFilePath) != ""
  4016.         LibraryProcedure !FullName, $(!DLLSQL), GetPrivProfStr, "License", "FullName", $(!IniFilePath)
  4017.         LibraryProcedure !OrgName, $(!DLLSQL), GetPrivProfStr, "License", "OrgName", $(!IniFilePath)
  4018.         LibraryProcedure !ProductID, $(!DLLSQL), GetPrivProfStr, "License", "ProductID", $(!IniFilePath)
  4019.         set Status = "STATUS_SUCCESSFUL"
  4020.         goto endDoLicense
  4021.     endif
  4022.     set Status   = "STATUS_FAILED"
  4023. start_fullnameorgname =+
  4024.     read-syms QueryFullNameOrgNameDlg$(!STF_LANGUAGE)
  4025.     LibraryProcedure DlgLicense, $(!DLLSQL), SQLDlgDisplay $(STF_HWND),$(DlgTemplate),"",$(!SQLDlgNames),"MODAL",""
  4026. fullnameorgname =+
  4027.     LibraryProcedure DLGEVENT, $(!DLLSQL), WaitEvent
  4028.     ifstr(i) $(DLGEVENT) == "CONTINUE"
  4029.         LibraryProcedure EditTextOut1, $(!DLLSQL), DlgGetEditText $(DlgLicense),"EDIT1"
  4030.         LibraryProcedure EditTextOut2, $(!DLLSQL), DlgGetEditText $(DlgLicense),"EDIT2"
  4031.         LibraryProcedure EditTextOut3, $(!DLLSQL), DlgGetEditText $(DlgLicense),"EDIT3"
  4032.         ifstr(i) $(EditTextOut1) == ""
  4033.             read-syms DBNoNameNOrg$(!STF_LANGUAGE)
  4034.             shell "" MessageError
  4035.             goto fullnameorgname
  4036.         else
  4037.             LibraryProcedure Result, $(!DLLSQL), CloseDialog $(DlgLicense)
  4038.             set !FullName = $(EditTextOut1)
  4039.             set !OrgName  = $(EditTextOut2)
  4040.             set !ProductID  = $(EditTextOut3)
  4041.             goto start_verifyfullnameorgname
  4042.         endif
  4043.     else-ifstr(i) $(DLGEVENT) == "CALLCOMBOKILLFOCUS1"
  4044.         goto fullnameorgname
  4045.     else-ifstr(i) $(DLGEVENT) == "EXIT"
  4046.         shell "" QueryUserQuit $(!STF_LANGUAGE)
  4047.         ifstr(i) $($R1) == "OK"
  4048.             set Status = "STATUS_USERQUIT"
  4049.             goto finish_license
  4050.         else
  4051.             set ReInit = NO
  4052.             goto fullnameorgname
  4053.         endif
  4054.     else
  4055.         goto finish_license
  4056.     endif
  4057.     
  4058.     start_verifyfullnameorgname = +
  4059.     read-syms VerifyFullNameOrgNameDlg$(!STF_LANGUAGE)
  4060.     LibraryProcedure DlgLicense, $(!DLLSQL), SQLDlgDisplay $(STF_HWND),$(DlgTemplate),"",$(!SQLDlgNames),"MODAL",""
  4061. verifyfullnameorgname =+
  4062.     LibraryProcedure DLGEVENT, $(!DLLSQL), WaitEvent
  4063.     ifstr(i) $(DLGEVENT) == "CONTINUE"
  4064.         set Status = "STATUS_SUCCESSFUL"
  4065.         set !LicenseSet = "TRUE"
  4066.         goto finish_license
  4067.     else-ifstr(i) $(DLGEVENT) == "CALLCOMBOKILLFOCUS1"
  4068.         goto verifyfullnameorgname
  4069.     else-ifstr(i) $(DLGEVENT) == "BACK"
  4070.         LibraryProcedure Result, $(!DLLSQL), CloseDialog $(DlgLicense)
  4071.         goto start_fullnameorgname
  4072.     else-ifstr(i) $(DLGEVENT) == "EXIT"
  4073.         shell "" QueryUserQuit $(!STF_LANGUAGE)
  4074.         ifstr(i) $($R1) == "OK"
  4075.             set Status = "STATUS_USERQUIT"
  4076.             goto finish_license
  4077.         else
  4078.             goto verifyfullnameorgname
  4079.         endif
  4080.     else
  4081.         goto finish_license
  4082.     endif
  4083.     finish_license = +
  4084.     ifstr(i) $(DlgLicense) != ""
  4085.         LibraryProcedure Result, $(!DLLSQL), CloseDialog $(DlgLicense)
  4086.     endif
  4087. endDoLicense =+
  4088.     Return $(Status)
  4089.         
  4090. [DoSetupType]
  4091.     ifstr(i) $(!IniFilePath) != ""
  4092.         set !InstallType = "1"
  4093.         set Status = "STATUS_SUCCESSFUL"
  4094.         goto endDoSetupType
  4095.     endif
  4096.     StartWait
  4097.     set Status = "STATUS_FAILED"
  4098.     ifstr(i) $(!Owner) == ""
  4099.         set PrevInstallType = "1"
  4100.     else
  4101.         set PrevInstallType = "2"
  4102.     endif
  4103.     read-syms InstallTypeChoicesDlg$(!STF_LANGUAGE)
  4104.     LibraryProcedure SetupTypeDlg, $(!DLLSQL), SQLDlgDisplay $(STF_HWND),$(DlgTemplate),"",$(!SQLDlgNames),"MODAL",""
  4105.     ifstr(i) $(!StandAlone) != ""
  4106.         LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(SetupTypeDlg),"DLGBUTTON1","FALSE"
  4107.     endif
  4108. start_setuptype =+
  4109.     ifstr(i) $(!EvalVersion) == "YES"
  4110.         LibraryProcedure SQLEvalKey, $(!DLLSQL), RegOpen "\\"$(!ComputerName),$(!RegSQLEvaluation)"\"$(!RegSQLEval)
  4111.         ifstr(i) $(SQLEvalKey) != "KEY_ERROR"
  4112.             ForListDo $(!EvalSet)
  4113.                 LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(SetupTypeDlg),"UNIBUTTON"$($),"FALSE"
  4114.             EndForListDo
  4115.             goto initbutton
  4116.         endif
  4117.     endif
  4118.  
  4119.     LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(SetupTypeDlg),"DLGBUTTON1","FALSE"
  4120.  
  4121.     ifstr(i) $(!Owner) == ""
  4122.         ForListDo $(!InstallSet)
  4123.             LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(SetupTypeDlg),"UNIBUTTON"$($),"FALSE"
  4124.         EndForListDo
  4125.     else
  4126.         ifstr(i) $(!SQL95Keys) == "TRUE"
  4127.             ForListDo $(!InstallSetInstld)
  4128.                 LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(SetupTypeDlg),"UNIBUTTON"$($),"FALSE"
  4129.             EndForListDo
  4130.         else
  4131.             ForListDo $(!InstallSetDual)
  4132.                 LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(SetupTypeDlg),"UNIBUTTON"$($),"FALSE"
  4133.             EndForListDo
  4134.         endif
  4135.     endif
  4136. initbutton =+
  4137.     LibraryProcedure Result, $(!DLLSQL), DlgCheckButton $(SetupTypeDlg),"UNIBUTTON"$(PrevInstallType),"UNIBUTTON1","UNIBUTTON9"
  4138. setuptype = +
  4139.     EndWait
  4140.     LibraryProcedure DLGEVENT, $(!DLLSQL), WaitEvent
  4141.     ifstr(i) $(DLGEVENT) == "CONTINUE"
  4142.         set Status = "STATUS_SUCCESSFUL"
  4143.         LibraryProcedure !InstallType, $(!DLLSQL), GetCheckedRadio $(SetupTypeDlg)
  4144.         ifstr(i) $(!InstallType) == "4"
  4145.             ifstr(i) $(!StandAlone) != ""
  4146.                 read-syms NoNetChangeDevVer
  4147.                 shell "" MessageError
  4148.                 goto setuptype
  4149.             endif
  4150.         endif
  4151.     else-ifstr(i) $(DLGEVENT) == "DLGBUTTON1"
  4152.         LibraryProcedure PrevInstallType, $(!DLLSQL), GetCheckedRadio $(SetupTypeDlg)
  4153.         read-syms RemoteCancel$(!STF_LANGUAGE)
  4154.         shell "" DoGetRemoteSetup
  4155.         ifstr(i) $($R0) == "STATUS_USERQUIT"
  4156.             set Status = $($R0)
  4157.             goto finish_options
  4158.         endif
  4159.         ifstr(i) $(!RemoteComputer) != $(!OldRemoteComputer)
  4160.             StartWait
  4161.             set !OldRemoteComputer = $(!RemoteComputer)
  4162.             ForListDo $(!CompleteInstSet)
  4163.                 LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(SetupTypeDlg),"UNIBUTTON"$($),"TRUE"
  4164.             EndForListDo
  4165.             ifstr(i) $(!Owner) == ""
  4166.                 ifcontains(i) $(PrevInstallType) in $(!InstallSet)
  4167.                     set PrevInstallType = "1"
  4168.                 endif
  4169.             else
  4170.                 ifstr(i) $(!SQL95Keys) == "TRUE"
  4171.                     ifcontains(i) $(PrevInstallType) in $(!InstallSetInstld)
  4172.                         set PrevInstallType = "2"
  4173.                     endif
  4174.                 else
  4175.                     ifcontains(i) $(PrevInstallType) in $(!InstallSetDual)
  4176.                         ifstr(i) $(PrevInstallType) == "1"
  4177.                             set PrevInstallType = "1"
  4178.                         else
  4179.                             set PrevInstallType = "2"
  4180.                         endif
  4181.                     endif
  4182.                 endif
  4183.             endif
  4184.             goto start_setuptype
  4185.         else
  4186.             goto setuptype
  4187.         endif
  4188.     else-ifstr(i) $(DLGEVENT) == "CALLCOMBOKILLFOCUS1"
  4189.         goto setuptype
  4190.     else-ifstr(i) $(DLGEVENT) == "EXIT"
  4191.         shell "" QueryUserQuit $(!STF_LANGUAGE)
  4192.         ifstr(i) $($R1) == "OK"
  4193.             set Status = "STATUS_USERQUIT"
  4194.         else
  4195.             goto setuptype
  4196.         endif
  4197.     endif
  4198.     finish_options = +
  4199.     LibraryProcedure Result, $(!DLLSQL), CloseDialog $(SetupTypeDlg)
  4200. endDoSetupType =+
  4201.     Return $(Status)
  4202.         
  4203. [DoGetRemoteSetup]
  4204.     set Status = "STATUS_FAILED"
  4205.     set RemSQLLog = "C"
  4206.     set RemNTLog = ""
  4207.     set RemDBLog = ""
  4208.     set LocalRemoteSQLDrive = ""
  4209.     set LocalRemoteNTDrive = ""
  4210.     set LocalRemoteDBDrive = ""
  4211.     set RemMode = "DLGBUTTON2"
  4212.     read-syms RemoteDlg$(!STF_LANGUAGE)
  4213.     LibraryProcedure RemoteDlg, $(!DLLSQL), SQLDlgDisplay $(STF_HWND),$(DlgTemplate),"",$(!SQLDlgNames),"MODAL",""
  4214.     ForListDo $(!SupportedRemoteShares)
  4215.         LibraryProcedure Result, $(!DLLSQL), DlgAddCmbEntry $(RemoteDlg),"CALLCOMBO1",$($)
  4216.     EndForListDo
  4217.     ifstr(i) $(!RemoteComputer) == ""
  4218.         LibraryProcedure Result, $(!DLLSQL), DlgSetCmbCurSel $(RemoteDlg),"CALLCOMBO1","BYINDEX","0"
  4219.         LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(RemoteDlg),"DLGBUTTON2","FALSE"
  4220.         LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(RemoteDlg),"DLGBUTTON3","FALSE"
  4221.         LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(RemoteDlg),"DLGBUTTON4","FALSE"
  4222.         LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(RemoteDlg),"EDIT1","FALSE"
  4223.         LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(RemoteDlg),"CALLCOMBO1","FALSE"
  4224.         LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(RemoteDlg),"TEXT1","FALSE"
  4225.         LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(RemoteDlg),"TEXT2","FALSE"
  4226.     else
  4227.         LibraryProcedure Result, $(!DLLSQL), DlgCheckButton $(RemoteDlg),"DLGBUTTON1","TRUE"
  4228.         LibraryProcedure Result, $(!DLLSQL), DlgSetEditText $(RemoteDlg),"EDIT1",$(!RemoteComputer)
  4229.         LibraryProcedure RemSQLLog, $(!DLLSQL), StrBeforeAndAfter $(!LogicalSQLDrive),"BEFORE",":"
  4230.         LibraryProcedure RemNTLog, $(!DLLSQL), StrBeforeAndAfter $(!LogicalNTDrive),"BEFORE",":"
  4231.         LibraryProcedure RemDBLog, $(!DLLSQL), StrBeforeAndAfter $(!LogicalDBDrive),"BEFORE",":"
  4232.         LibraryProcedure Result, $(!DLLSQL), DlgSetCmbCurSel $(RemoteDlg),"CALLCOMBO1","BYENTRY",$(RemSQLLog)
  4233.     endif
  4234.     ifstr(i) $(!StandAlone) != ""
  4235.         LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(RemoteDlg),"DLGBUTTON1","FALSE"
  4236.     endif
  4237.     remoteset = +
  4238.     LibraryProcedure DLGEVENT, $(!DLLSQL), WaitEvent
  4239.     ifstr(i) $(DLGEVENT) == "CONTINUE"
  4240.         LibraryProcedure LocalCB, $(!DLLSQL), IsDlgBtnChecked $(RemoteDlg),"DLGBUTTON1"
  4241.         ifstr(i) $(LocalCB) != "CHECKED"
  4242.             ifstr(i) $(!RemoteSQLDrive) != ""
  4243.                 LibraryProcedure Result, $(!DLLSQL), NETDriveOperation "DISCONNECT","","",$(!RemoteSQLDrive)
  4244.                 set !RemoteSQLDrive = ""
  4245.             endif
  4246.             ifstr(i) $(!RemoteNTDrive) != ""
  4247.                 LibraryProcedure Result, $(!DLLSQL), NETDriveOperation "DISCONNECT","","",$(!RemoteNTDrive)
  4248.                 set !RemoteNTDrive = ""
  4249.             endif
  4250.             ifstr(i) $(!RemoteDBDrive) != ""
  4251.                 LibraryProcedure Result, $(!DLLSQL), NETDriveOperation "DISCONNECT","","",$(!RemoteDBDrive)
  4252.                 set !RemoteDBDrive = ""
  4253.             endif
  4254.             shell "" DoSetLocalSetup
  4255.             ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  4256.                 set Status = "STATUS_USERQUIT"
  4257.             else
  4258.                 set Status = "STATUS_SUCCESSFUL"
  4259.             endif
  4260.             goto end_remoteset
  4261.         endif
  4262.         
  4263.         LibraryProcedure LocalRemoteComputer, $(!DLLSQL), DlgGetEditText $(RemoteDlg),"EDIT1"
  4264.         LibraryProcedure Temp, $(!DLLSQL), StrBeforeAndAfter $(LocalRemoteComputer),"LASTAFTER","\"
  4265.         ifstr(i) $(Temp) != ""
  4266.             set LocalRemoteComputer = $(Temp)
  4267.         endif
  4268.         
  4269.         ifstr(i) $(LocalRemoteComputer) == ""
  4270.             read-syms NoRemoteSpec$(!STF_LANGUAGE)
  4271.             shell "" MessageError
  4272.             goto remoteset
  4273.         endif
  4274.         ifstr(i) $(RemNTLog) == ""
  4275.             set RemNTLog = $(RemSQLLog)
  4276.         endif
  4277.         ifstr(i) $(RemDBLog) == ""
  4278.             set RemDBLog = $(RemSQLLog)
  4279.         endif
  4280.         
  4281.         detect ReadUnusedDrives
  4282.         shell "" AllocateUnusedDrive
  4283.         ifstr(i) $($R0) == "STATUS_FAILED"
  4284.             read-syms CannotAllocUnusedDrive$(!STF_LANGUAGE)
  4285.             shell "" MessageError
  4286.             goto remoteset
  4287.         else
  4288.             set LocalRemoteSQLDrive = $($R1)
  4289.         endif
  4290.         ifstr(i) $(RemNTLog) != $(RemSQLLog)
  4291.             shell "" AllocateUnusedDrive
  4292.             ifstr(i) $($R0) == "STATUS_FAILED"
  4293.                 read-syms CannotAllocUnusedDrive$(!STF_LANGUAGE)
  4294.                 shell "" MessageError
  4295.                 goto remoteset
  4296.             else
  4297.                 set LocalRemoteNTDrive = $($R1)
  4298.             endif
  4299.         else
  4300.             set LocalRemoteNTDrive = $(LocalRemoteSQLDrive)
  4301.         endif
  4302.         ifstr(i) $(RemDBLog) != $(RemSQLLog)
  4303.             ifstr(i) $(RemDBLog) != $(RemNTLog)
  4304.                 shell "" AllocateUnusedDrive
  4305.                 ifstr(i) $($R0) == "STATUS_FAILED"
  4306.                     read-syms CannotAllocUnusedDrive$(!STF_LANGUAGE)
  4307.                     shell "" MessageError
  4308.                     goto remoteset
  4309.                 else
  4310.                     set LocalRemoteDBDrive = $($R1)
  4311.                 endif
  4312.             else
  4313.                 set LocalRemoteDBDrive = $(LocalRemoteNTDrive)
  4314.             endif
  4315.         else
  4316.             set LocalRemoteDBDrive = $(LocalRemoteSQLDrive)
  4317.         endif
  4318.         
  4319.         set ErrText = ""
  4320.         LibraryProcedure Result, $(!DLLSQL), NETDriveOperation "CONNECT","\\"$(LocalRemoteComputer)"\"$(RemSQLLog)"$","",$(LocalRemoteSQLDrive)
  4321.         ifstr(i) $(Result) != ""
  4322.             read-syms NetworkDriveConnectError$(!STF_LANGUAGE)
  4323.             LibraryProcedure ErrText, $(!DLLSQL), AppendToString $(ErrText),$(!AddlText)
  4324.             read-syms NetworkDriveConnectSQLInst$(!STF_LANGUAGE)
  4325.             LibraryProcedure ErrText, $(!DLLSQL), AppendToString $(ErrText),$(!AddlText)
  4326.             LibraryProcedure !AddlText, $(!DLLSQL), AppendToString $(ErrText),$(Result)
  4327.             shell "" MessageError
  4328.             goto remoteset
  4329.         endif
  4330.         ifstr(i) $(RemNTLog) != $(RemSQLLog)
  4331.             LibraryProcedure Result, $(!DLLSQL), NETDriveOperation "CONNECT","\\"$(LocalRemoteComputer)"\"$(RemNTLog)"$","",$(LocalRemoteNTDrive)
  4332.             ifstr(i) $(Result) != ""
  4333.                 read-syms NetworkDriveConnectError$(!STF_LANGUAGE)
  4334.                 LibraryProcedure ErrText, $(!DLLSQL), AppendToString $(ErrText),$(!AddlText)
  4335.                 read-syms NetworkDriveConnectNTInst$(!STF_LANGUAGE)
  4336.                 LibraryProcedure ErrText, $(!DLLSQL), AppendToString $(ErrText),$(!AddlText)
  4337.                 LibraryProcedure !AddlText, $(!DLLSQL), AppendToString $(ErrText),$(Result)
  4338.                 shell "" MessageError
  4339.                 LibraryProcedure Result, $(!DLLSQL), NETDriveOperation "DISCONNECT","","",$(LocalRemoteSQLDrive)
  4340.                 goto remoteset
  4341.             endif
  4342.         endif
  4343.         ifstr(i) $(RemDBLog) != $(RemSQLLog)
  4344.             ifstr(i) $(RemDBLog) != $(RemNTLog)
  4345.                 LibraryProcedure Result, $(!DLLSQL), NETDriveOperation "CONNECT","\\"$(LocalRemoteComputer)"\"$(RemDBLog)"$","",$(LocalRemoteDBDrive)
  4346.                 ifstr(i) $(Result) != ""
  4347.                     read-syms NetworkDriveConnectError$(!STF_LANGUAGE)
  4348.                     LibraryProcedure ErrText, $(!DLLSQL), AppendToString $(ErrText),$(!AddlText)
  4349.                     read-syms NetworkDriveConnectDBInst$(!STF_LANGUAGE)
  4350.                     LibraryProcedure ErrText, $(!DLLSQL), AppendToString $(ErrText),$(!AddlText)
  4351.                     LibraryProcedure !AddlText, $(!DLLSQL), AppendToString $(ErrText),$(Result)
  4352.                     shell "" MessageError
  4353.                     LibraryProcedure Result, $(!DLLSQL), NETDriveOperation "DISCONNECT","","",$(LocalRemoteSQLDrive)
  4354.                     ifstr(i) $(RemNTLog) != $(RemSQLLog)
  4355.                         LibraryProcedure Result, $(!DLLSQL), NETDriveOperation "DISCONNECT","","",$(LocalRemoteNTDrive)
  4356.                     endif
  4357.                     goto remoteset
  4358.                 endif
  4359.             endif
  4360.         endif
  4361.         
  4362.         ifstr(i) $(!RemoteSQLDrive) != ""
  4363.             LibraryProcedure Result, $(!DLLSQL), NETDriveOperation "DISCONNECT","","",$(!RemoteSQLDrive)
  4364.         endif
  4365.         ifstr(i) $(!RemoteNTDrive) != ""
  4366.             LibraryProcedure Result, $(!DLLSQL), NETDriveOperation "DISCONNECT","","",$(!RemoteNTDrive)
  4367.         endif
  4368.         ifstr(i) $(!RemoteDBDrive) != ""
  4369.             LibraryProcedure Result, $(!DLLSQL), NETDriveOperation "DISCONNECT","","",$(!RemoteDBDrive)
  4370.         endif
  4371.         
  4372.         set !StandAlone = ""
  4373.         set !RemoteSQLDrive = $(LocalRemoteSQLDrive)
  4374.         set !RemoteNTDrive = $(LocalRemoteNTDrive)
  4375.         set !RemoteDBDrive = $(LocalRemoteDBDrive)
  4376.         set !LogicalSQLDrive = $(RemSQLLog)":"
  4377.         set !LogicalDBDrive = $(RemDBLog)":"
  4378.         set !LogicalNTDrive = $(RemNTLog)":"
  4379.         shell "" RestoreOldAliasName
  4380.         shell "" GetAliasConnectTo $(LocalRemoteComputer)
  4381.         set !ComputerName = $(LocalRemoteComputer)
  4382.         set !ServerName = $(!ComputerName)
  4383.         set !RemoteComputer = $(!ComputerName)
  4384.         set !DefSQLPath = $(!RemoteSQLDrive)"\"$(!DefSQLStub)
  4385.         set !LogicalSystemMemory = $(!MinSystemMemory)
  4386.         
  4387.         LibraryProcedure Key, $(!DLLSQL), RegOpen "\\"$(!ComputerName),$(!RegSQLWinNT)
  4388.         ifstr(i) $(Key) != "KEY_ERROR"
  4389.             LibraryProcedure !SystemDirectory, $(!DLLSQL), RegRead $(Key),$(!RegValSystemRoot)
  4390.             LibraryProcedure Temp, $(!DLLSQL), StrBeforeAndAfter $(!SystemDirectory),"AFTER",":"
  4391.             set !RemoteSystemRoot = $(!LogicalNTDrive)$(Temp)
  4392.             set !LocalRemoteSystemRoot = $(!RemoteNTDrive)$(Temp)
  4393.             set !SystemDirectory = $(!RemoteNTDrive)$(Temp)"\"$(!SystemDir)
  4394.             LibraryProcedure Result, $(!DLLSQL), RegClose $(Key)
  4395.         endif
  4396.         LibraryProcedure TempName, $(!DLLSQL), GetMachineName
  4397.         ifstr(i) $(!SQL95Keys) != "TRUE"
  4398.             shell "" DoDelete95Key $(TempName), ""
  4399.         endif
  4400.         LibraryProcedure TestKey, $(!DLLSQL), RegOpen "\\"$(!ComputerName),$(!RegSQLServerServer)
  4401.         ifstr(i) $(TestKey) != "KEY_ERROR"
  4402.             set !SQL95Keys = "TRUE"
  4403.             LibraryProcedure Result, $(!DLLSQL), RegClose $(TestKey)
  4404.         else
  4405.             shell "" DoDupKeys
  4406.             ifstr(i) $($R1) == "STATUS_FAILED"
  4407.                 goto doneremote
  4408.             endif
  4409.             set !SQL95Keys = "FALSE"
  4410.             ifstr(i) $($R0) == "STATUS_SUCCESSFUL"
  4411.                 set !RemoteKeysDupped = "TRUE"
  4412.             else
  4413.                 set !RemoteKeysDupped = "FALSE"
  4414.             endif
  4415.         endif
  4416.         shell "" GetPreviousInstallationInfo
  4417.         ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  4418.             set Status = "STATUS_USERQUIT"
  4419.             goto end_remoteset
  4420.         endif
  4421.         set Status = "STATUS_SUCCESSFUL"
  4422.     else-ifstr(i) $(DLGEVENT) == "DLGBUTTON1"
  4423.         LibraryProcedure Result, $(!DLLSQL), IsDlgBtnChecked $(RemoteDlg),"DLGBUTTON1"
  4424.         ifstr(i) $(Result) == "CHECKED"
  4425.             LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(RemoteDlg),"EDIT1","TRUE"
  4426.             LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(RemoteDlg),"CALLCOMBO1","TRUE"
  4427.             LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(RemoteDlg),"TEXT1","TRUE"
  4428.             LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(RemoteDlg),"TEXT2","TRUE"
  4429.             LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(RemoteDlg),"DLGBUTTON2","TRUE"
  4430.             LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(RemoteDlg),"DLGBUTTON3","TRUE"
  4431.             LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(RemoteDlg),"DLGBUTTON4","TRUE"
  4432.             goto remoteset
  4433.         else
  4434.             LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(RemoteDlg),"EDIT1","FALSE"
  4435.             LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(RemoteDlg),"CALLCOMBO1","FALSE"
  4436.             LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(RemoteDlg),"TEXT1","FALSE"
  4437.             LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(RemoteDlg),"TEXT2","FALSE"
  4438.             LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(RemoteDlg),"DLGBUTTON2","FALSE"
  4439.             LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(RemoteDlg),"DLGBUTTON3","FALSE"
  4440.             LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(RemoteDlg),"DLGBUTTON4","FALSE"
  4441.             goto remoteset
  4442.         endif
  4443.     else-ifstr(i) $(DLGEVENT) == "DLGBUTTON2"
  4444.         set RemMode = $(DLGEVENT)
  4445.         LibraryProcedure Result, $(!DLLSQL), DlgSetCmbCurSel $(RemoteDlg),"CALLCOMBO1","BYENTRY",$(RemSQLLog)
  4446.         goto remoteset
  4447.     else-ifstr(i) $(DLGEVENT) == "DLGBUTTON3"
  4448.         set RemMode = $(DLGEVENT)
  4449.         ifstr(i) $(RemNTLog) == ""
  4450.             set TheLog = $(RemSQLLog)
  4451.         else
  4452.             set TheLog = $(RemNTLog)
  4453.         endif
  4454.         LibraryProcedure Result, $(!DLLSQL), DlgSetCmbCurSel $(RemoteDlg),"CALLCOMBO1","BYENTRY",$(TheLog)
  4455.         goto remoteset
  4456.     else-ifstr(i) $(DLGEVENT) == "DLGBUTTON4"
  4457.         set RemMode = $(DLGEVENT)
  4458.         ifstr(i) $(RemDBLog) == ""
  4459.             set TheLog = $(RemSQLLog)
  4460.         else
  4461.             set TheLog = $(RemDBLog)
  4462.         endif
  4463.         LibraryProcedure Result, $(!DLLSQL), DlgSetCmbCurSel $(RemoteDlg),"CALLCOMBO1","BYENTRY",$(TheLog)
  4464.         goto remoteset
  4465.     else-ifstr(i) $(DLGEVENT) == "CALLCOMBOKILLFOCUS1"
  4466.         goto remoteset
  4467.     else-ifstr(i) $(DLGEVENT) == "CALLCOMBO1"
  4468.         LibraryProcedure Result, $(!DLLSQL), DlgGetCmbCurText $(RemoteDlg),"CALLCOMBO1",""
  4469.         ifstr(i) $(RemMode) == "DLGBUTTON2"
  4470.             set RemSQLLog = $(Result)
  4471.         else-ifstr(i) $(RemMode) == "DLGBUTTON3"
  4472.             set RemNTLog = $(Result)
  4473.         else-ifstr(i) $(RemMode) == "DLGBUTTON4"
  4474.             set RemDBLog = $(Result)
  4475.         endif
  4476.         goto remoteset
  4477.     else-ifstr(i) $(DLGEVENT) == "EXIT"
  4478.         set Status = "STATUS_BACK"
  4479.     else
  4480.         goto remoteset
  4481.     endif
  4482. end_remoteset =+
  4483.     ifstr(i) $(Status) != "STATUS_SUCCESSFUL"
  4484.         ifstr(i) $(LocalRemoteSQLDrive) != ""
  4485.             LibraryProcedure Result, $(!DLLSQL), NETDriveOperation "DISCONNECT","","",$(LocalRemoteSQLDrive)
  4486.         endif
  4487.         ifstr(i) $(LocalRemoteNTDrive) != ""
  4488.             LibraryProcedure Result, $(!DLLSQL), NETDriveOperation "DISCONNECT","","",$(LocalRemoteNTDrive)
  4489.         endif
  4490.         ifstr(i) $(LocalRemoteDBDrive) != ""
  4491.             LibraryProcedure Result, $(!DLLSQL), NETDriveOperation "DISCONNECT","","",$(LocalRemoteDBDrive)
  4492.         endif
  4493.     endif
  4494. doneremote =+
  4495.     LibraryProcedure Result, $(!DLLSQL), CloseDialog $(RemoteDlg)
  4496.     ifstr(i) $(Status) == "STATUS_SUCCESSFUL"
  4497.         shell "" DoCheckOS
  4498.     endif
  4499.     Return $(Status)
  4500.         
  4501. [DoSetLocalSetup]
  4502.     set Status = "STATUS_SUCCESSFUL"
  4503.     set !RemoteComputer = ""
  4504.     set !LogicalSQLDrive = $(!Primary)
  4505.     set !LogicalDBDrive = $(!Primary)
  4506.     set !LogicalNTDrive = $(!Primary)
  4507.     set !SystemDirectory = $(!STF_WINDOWSSYSPATH)
  4508.     set !LogicalSystemMemory = $(!SystemMemory)
  4509.     LibraryProcedure !ComputerName, $(!DLLSQL), GetMachineName
  4510.     
  4511.     ifstr(i) $(!SQLReleaseNumber) == $(!StandAloneRelease)
  4512.         set !StandAlone = "1"
  4513.         set !ServerName = ""
  4514.     else
  4515.         ifstr(i) $(!STF_OS) == "NT"
  4516.             LibraryProcedure Result, $(!DLLSQL), GetServiceState "\\"$(!ComputerName),$(!LANManWksta)
  4517.             ifstr(i) $(Result) != "SERVICE_RUNNING"
  4518.                 set !StandAlone = "1"
  4519.                 set !ServerName = ""
  4520.             else
  4521.                 set !StandAlone = ""
  4522.                 set !ServerName = $(!ComputerName)
  4523.             endif
  4524.         else
  4525.             set !StandAlone = "1"
  4526.             set !ServerName = ""
  4527.         endif
  4528.     endif
  4529.     set !DefSQLPath = $(!Primary)"\"$(!DefSQLStub)
  4530.     
  4531.     ifstr(i) $(!RegistryRebuild) == ""
  4532.         shell "" GetPreviousInstallationInfo
  4533.         ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  4534.             set Status = "STATUS_FAILED"
  4535.         endif
  4536.     else
  4537.         LibraryProcedure !AdminACL, $(!DLLSQL), CreateSecurityAttribute "\\"$(!ComputerName),$(!AdministratorsGroup),"GENERIC_ALL","BUILTIN"
  4538.         ifstr(i) $(!AdminACL) == "CANNOT_CREATE_ACL"
  4539.             set !AdminACL = ""
  4540.         endif
  4541.         LibraryProcedure Key, $(!DLLSQL), RegOpen "\\"$(!ComputerName),$(!RegOldSQLSetup)
  4542.         ifstr(i) $(Key) != "KEY_ERROR"
  4543.             LibraryProcedure !OldSQLPath, $(!DLLSQL), RegRead $(Key),$(!RegValSQLPath)
  4544.             LibraryProcedure Result, $(!DLLSQL), RegClose $(Key)
  4545.         endif
  4546.     endif
  4547.     Return $(Status)
  4548.         
  4549. [DoNewOptions]
  4550.     ifstr(i) $(!IniFilePath) != ""
  4551.         shell "" DoCharSet
  4552.         shell "" DoSortOrder
  4553.         shell "" DoScripts
  4554.         ifstr(i) $(!StandAlone) == ""
  4555.             shell "" DoNetwork
  4556.         endif
  4557.         LibraryProcedure !AutoServerService, $(!DLLSQL) GetPrivProfStr "NewOptions", "AutoServerService", $(!IniFilePath)
  4558.         LibraryProcedure !AutoSchedulerService, $(!DLLSQL) GetPrivProfStr "NewOptions", "AutoExecutiveService", $(!IniFilePath)
  4559.         set !TheCharSetPath = $(!SQLPath)"\"$(!CharSets)"\"$(!TheCharSet)
  4560.         set Status = STATUS_SUCCESSFUL
  4561.         goto endDoNewOptions
  4562.     endif
  4563.     StartWait
  4564.     set Status = "STATUS_FAILED"
  4565.     read-syms NewInstallOptionsDlg$(!STF_LANGUAGE)
  4566.     LibraryProcedure DlgNewOptions, $(!DLLSQL), SQLDlgDisplay $(STF_HWND),$(DlgTemplate),"",$(!SQLDlgNames),"MODAL",""
  4567.     QueryListSize NumNets $(!NetLibList)
  4568.     ifstr(i) $(!StandAlone) == ""
  4569.         LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(DlgNewOptions),"DLGBUTTON4","TRUE"
  4570.     else
  4571.         LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(DlgNewOptions),"DLGBUTTON4","FALSE"
  4572.     endif
  4573.     EndWait
  4574.     newoptions = +
  4575.     LibraryProcedure DLGEVENT, $(!DLLSQL), WaitEvent
  4576.     ifstr(i) $(DLGEVENT) == "EXIT"
  4577.         shell "" QueryUserQuit $(!STF_LANGUAGE)
  4578.         ifstr(i) $($R1) == "OK"
  4579.             set Status = "STATUS_USERQUIT"
  4580.             goto finish_newoptions
  4581.         else
  4582.             goto newoptions
  4583.         endif
  4584.     else-ifstr(i) $(DLGEVENT) == "BACK"
  4585.         set Status = "STATUS_BACK"
  4586.         goto finish_newoptions
  4587.     else-ifstr(i) $(DLGEVENT) == "CONTINUE"
  4588.         LibraryProcedure !AutoServerService, $(!DLLSQL), IsDlgBtnChecked $(DlgNewOptions),"DLGBUTTON5"
  4589.         LibraryProcedure !AutoSchedulerService, $(!DLLSQL), IsDlgBtnChecked $(DlgNewOptions),"DLGBUTTON6"
  4590.         set !TheCharSetPath = $(!SQLPath)"\"$(!CharSets)"\"$(!TheCharSet)
  4591.         set Status = "STATUS_SUCCESSFUL"
  4592.         goto finish_newoptions
  4593.     else-ifstr(i) $(DLGEVENT) == "DLGBUTTON1"
  4594.         shell "" DoCharSet
  4595.         goto newoptions
  4596.     else-ifstr(i) $(DLGEVENT) == "DLGBUTTON2"
  4597.         shell "" DoSortOrder
  4598.         goto newoptions
  4599.     else-ifstr(i) $(DLGEVENT) == "DLGBUTTON3"
  4600.         shell "" DoLanguage
  4601.         goto newoptions
  4602.     else-ifstr(i) $(DLGEVENT) == "DLGBUTTON4"
  4603.         set !AllowExit = "NO"
  4604.         shell "" DoNetwork
  4605.         set !AllowExit = "YES"
  4606.         goto newoptions
  4607.     else-ifstr(i) $(DLGEVENT) == "DLGBUTTON5"
  4608.         LibraryProcedure Result, $(!DLLSQL), IsDlgBtnChecked $(DlgNewOptions),"DLGBUTTON6"
  4609.         ifstr(i) $(Result) != "CHECKED"
  4610.             LibraryProcedure Result, $(!DLLSQL), DlgCheckButton $(DlgNewOptions),"DLGBUTTON7","FALSE"
  4611.         endif
  4612.         goto newoptions
  4613.     else-ifstr(i) $(DLGEVENT) == "DLGBUTTON6"
  4614.         LibraryProcedure Result, $(!DLLSQL), IsDlgBtnChecked $(DlgNewOptions),"DLGBUTTON7"
  4615.         ifstr(i) $(Result) == "CHECKED"
  4616.             LibraryProcedure Result, $(!DLLSQL), DlgCheckButton $(DlgNewOptions),"DLGBUTTON6","TRUE"
  4617.         endif
  4618.         goto newoptions
  4619.     endif
  4620.     finish_newoptions = +
  4621.     LibraryProcedure Result, $(!DLLSQL), CloseDialog $(DlgNewOptions)
  4622. endDoNewOptions =+
  4623.     Return $(Status)
  4624.     
  4625. [DoSetFreeDiskSpace]
  4626.     LibraryProcedure FreeFormattedSpace, $(!DLLSQL), GetDriveFreeSpace $($1)"\"
  4627.     LibraryProcedure FreeSpace, $(!DLLSQL), GetDriveFreeSpace $($1)"\","UNFORMATTED"
  4628.     ifstr(i) $(FreeFormattedSpace) == "PLENTY"
  4629.         read-syms STR_Plenty
  4630.         LibraryProcedure Result, $(!DLLSQL), DlgSetEditText $($0),$($2),$(!AddlText)
  4631.     else
  4632.         LibraryProcedure Result, $(!DLLSQL), DlgSetEditText $($0),$($2),$(FreeFormattedSpace)
  4633.     endif
  4634.     set Status = "STATUS_SUCCESSFUL"
  4635.     Return $(Status),$(FreeSpace)
  4636.     
  4637. [BuildMSDB]
  4638.     LibraryProcedure Result, $(!DLLSQL), SQLLogin $(!LoginSleepPeriod),$(!LoginSleepRetrys),$(!ServerName),$(!SALogin),$(!SAPassword)
  4639.     ifstr(i) $(Result) == "NO_SERVER"
  4640.         read-syms NoLoginToSQLServer$(!STF_LANGUAGE)
  4641.         LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)
  4642.         goto end_buildmsdb
  4643.     endif
  4644.  
  4645.     LibraryProcedure Result, $(!DLLSQL), SQLDBUse $(!Master)
  4646.  
  4647.     ifstr(i) $(!RemoteComputer) == ""
  4648.         set NewMasterDBPath = $(!MasterDBPath)
  4649.     else
  4650.         LibraryProcedure Temp, $(!DLLSQL), StrBeforeAndAfter $(!MasterDBPath),"AFTER",":"
  4651.         LibraryProcedure NewMasterDBPath, $(!DLLSQL), AppendToString $(!LogicalDBDrive),$(Temp)
  4652.     endif
  4653.     
  4654.     LibraryProcedure Result, $(!DLLSQL), Delnode "FILE_DELETE", $(NewMasterDBPath)"\"$(!MSDBDataDat)
  4655.     LibraryProcedure Result, $(!DLLSQL), Delnode "FILE_DELETE", $(NewMasterDBPath)"\"$(!MSDBDataLog)
  4656.     
  4657.     StartWait
  4658.  
  4659.     LibraryProcedure VDevNumber, $(!DLLSQL), GetNextDevNo $(!SQLGetDevNo)
  4660.     ifstr(i) $(VDevNumber) == "-1"
  4661.         read-syms CantGetDevNo$(!STF_LANGUAGE)
  4662.         LibraryProcedure Result, $(!DLLSQL), SQLLogout
  4663.         goto end_buildmsdb
  4664.     endif
  4665.     LibraryProcedure Result, $(!DLLSQL), SQLExecute $(!SQLDiskInit)"'"$(!MSDBData)"',"$(!Physname)$(NewMasterDBPath)"\"$(!MSDBDataDat)"',"$(!VdevDatPlus)$(VDevNumber)$(!VdevDatNo)
  4666.     ifstr(i) $(Result) == "BAD_SQL_EXEC"
  4667.         read-syms SQLExecError$(!STF_LANGUAGE)
  4668.         LibraryProcedure !AddlText, $(!DLLSQL), SQLGetErrorMsg
  4669.         LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)
  4670.         LibraryProcedure Result, $(!DLLSQL), SQLLogout
  4671.         goto end_buildmsdb
  4672.     endif
  4673.     LibraryProcedure VDevNumber, $(!DLLSQL), GetNextDevNo $(!SQLGetDevNo)
  4674.     ifstr(i) $(VDevNumber) == "-1"
  4675.         read-syms CantGetDevNo$(!STF_LANGUAGE)
  4676.         LibraryProcedure Result, $(!DLLSQL), SQLLogout
  4677.         goto end_buildmsdb
  4678.     endif
  4679.     LibraryProcedure Result, $(!DLLSQL), SQLExecute $(!SQLDiskInit)"'"$(!MSDBLog)"',"$(!Physname)$(NewMasterDBPath)"\"$(!MSDBDataLog)"',"$(!VdevLogPlus)$(VDevNumber)$(!VdevLogNo)
  4680.     ifstr(i) $(Result) == "BAD_SQL_EXEC"
  4681.         read-syms SQLExecError$(!STF_LANGUAGE)
  4682.         LibraryProcedure !AddlText, $(!DLLSQL), SQLGetErrorMsg
  4683.         LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)
  4684.         LibraryProcedure Result, $(!DLLSQL), SQLLogout
  4685.         goto end_buildmsdb
  4686.     endif
  4687.     LibraryProcedure Result, $(!DLLSQL), SQLLogout
  4688.     
  4689.     set Status = "STATUS_SUCCESSFUL"
  4690. end_buildmsdb =+
  4691.     EndWait
  4692.     Return
  4693.         
  4694. [ExecNReturnSQLCmd]
  4695.     set Status = "STATUS_FAILED"
  4696.     set Data   = ""
  4697.     LibraryProcedure Result, $(!DLLSQL), SQLAddtoCmdBuff $($0)
  4698.     LibraryProcedure Result, $(!DLLSQL), SQLExecuteCmdBuff
  4699.     ifstr(i) $(Result) == "BAD_SQL_EXEC"
  4700.         read-syms SQLExecError$(!STF_LANGUAGE)
  4701.         LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)$(!LF)
  4702.         LibraryProcedure !AddlText, $(!DLLSQL), SQLGetErrorMsg
  4703.         LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)$(!LF)
  4704.         set Status = "STATUS_FAILED"
  4705.         goto finish_sqlexec
  4706.     endif
  4707.     LibraryProcedure Result, $(!DLLSQL), SQLGetNextResultSet
  4708.     ifstr(i) $(Result) != "BAD_RESULTS"
  4709.         LibraryProcedure Result, $(!DLLSQL), SQLBindColumn $($1), "1"
  4710.         LibraryProcedure Result, $(!DLLSQL), SQLNextRow $(!OneNextRow)
  4711.         LibraryProcedure Data, $(!DLLSQL), SQLGetBindingData "1"
  4712.         LibraryProcedure Result, $(!DLLSQL), SQLNextRow $(!PurgeRows)
  4713.     endif
  4714.     set Status = "STATUS_SUCCESSFUL"
  4715. finish_sqlexec =+
  4716.     Return $(Status) $(Data)
  4717.         
  4718. [DoGetPath]
  4719.     set Status = "STATUS_FAILED"
  4720.     start_getpath = +
  4721.     ifstr(i) $(!DlgEdit) == ""
  4722.         read-syms GetPathDlg$(!STF_LANGUAGE)
  4723.         LibraryProcedure !DlgEdit, $(!DLLSQL), SQLDlgDisplay $(STF_HWND),$(DlgTemplate),"",$(!SQLDlgNames),"",""
  4724.     endif
  4725.     getpath = +
  4726.     LibraryProcedure DLGEVENT, $(!DLLSQL), WaitEvent
  4727.     ifstr(i) $(DLGEVENT) == "EXIT"
  4728.         ifstr(i) $(!AllowExit) == "YES"
  4729.             shell "" QueryUserQuit $(!STF_LANGUAGE)
  4730.             ifstr(i) $($R1) == "OK"
  4731.                 set Status = "STATUS_USERQUIT"
  4732.             else
  4733.                 goto getpath
  4734.             endif
  4735.         else
  4736.             set Status = STATUS_CANCEL
  4737.         endif
  4738.     else-ifstr(i) $(DLGEVENT) == "BACK"
  4739.         set Status = "STATUS_BACK"
  4740.     else-ifstr(i) $(DLGEVENT) == "CONTINUE"
  4741.         LibraryProcedure EditTextOut, $(!DLLSQL), DlgGetEditText $(!DlgEdit),"EDIT1"
  4742.         ifstr(i) $(EditTextOut) == ""
  4743.             ifstr(i) $(!PermitNullName) == "NO"
  4744.                 read-syms $(!NoNameText)
  4745.                 shell "" MessageError
  4746.                 goto getpath
  4747.             endif
  4748.         endif
  4749.         set Status = "STATUS_SUCCESSFUL"
  4750.         set !PathOut = $(EditTextOut)
  4751.         ifstr(i) $(!CreatePathPrompt) == "YES"
  4752.             set DEST = $(!PathOut)
  4753.             detect DetectDirectory
  4754.             ifstr $(DirectoryThere) == "NO"
  4755.                 shell "" DoCreateDirectory
  4756.                 ifstr(i) $($R0) == "STATUS_YES"
  4757.                     set !CreatePath = "YES"
  4758.                 else
  4759.                     goto getpath
  4760.                 endif
  4761.             endif
  4762.         endif
  4763.     endif
  4764.     ifstr(i) $(!AutoPopoff) == "YES"
  4765.         LibraryProcedure Result, $(!DLLSQL), CloseDialog $(!DlgEdit)
  4766.         set !DlgEdit = ""
  4767.     endif
  4768.     Return $(Status)
  4769.         
  4770. [DoGetSpaceSQLPath]
  4771.     ifstr(i) $(!IniFilePath) != ""
  4772.         LibraryProcedure CurDrv, $(!DLLSQL), GetPrivProfStr "SQLPath", "LogicalSQLDrive", $(!IniFilePath)
  4773.         LibraryProcedure Temp, $(!DLLSQL), GetPrivProfStr "SQLPath", "SQLPath", $(!IniFilePath)
  4774.         set File = ""
  4775.         set Status = STATUS_SUCCESSFUL
  4776.         goto endDoGetSpaceSQLPath
  4777.     endif
  4778.     StartWait
  4779.     read-syms $($0)
  4780.     LibraryProcedure DlgSpaceSQLPath, $(!DLLSQL), SQLDlgDisplay $(STF_HWND),$(DlgTemplate),"",$(!SQLDlgNames),"MODAL",""
  4781.     ifstr(i) $(!RemoteComputer) == ""
  4782.         LibraryProcedure HardDrives, $(!DLLSQL), ListDriveTypes $($3)
  4783.         ForListDo $(HardDrives)
  4784.             LibraryProcedure Result, $(!DLLSQL), DlgAddCmbEntry $(DlgSpaceSQLPath),"CALLCOMBO1",$($)
  4785.         EndForListDo
  4786.         ifstr(i) $($6) != ""
  4787.             LibraryProcedure Result, $(!DLLSQL), DlgSetCmbCurSel $(DlgSpaceSQLPath),"CALLCOMBO1","BYENTRY",$($6)
  4788.         else
  4789.             LibraryProcedure Result, $(!DLLSQL), DlgSetCmbCurSel $(DlgSpaceSQLPath),"CALLCOMBO1","BYINDEX","0"
  4790.         endif
  4791.     else
  4792.         ifstr(i) $(!InstallType) == "2"
  4793.             ifstr(i) $($7) == "MASTERPATH"
  4794.                 LibraryProcedure Result, $(!DLLSQL), DlgAddCmbEntry $(DlgSpaceSQLPath),"CALLCOMBO1",$(!RemoteDBDrive)
  4795.             else
  4796.                 LibraryProcedure Result, $(!DLLSQL), DlgAddCmbEntry $(DlgSpaceSQLPath),"CALLCOMBO1",$(!RemoteSQLDrive)
  4797.             endif
  4798.         else
  4799.             LibraryProcedure Result, $(!DLLSQL), DlgAddCmbEntry $(DlgSpaceSQLPath),"CALLCOMBO1",$(!RemoteSQLDrive)
  4800.         endif
  4801.         LibraryProcedure Result, $(!DLLSQL), DlgSetCmbCurSel $(DlgSpaceSQLPath),"CALLCOMBO1","BYINDEX","0"
  4802.         LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(DlgSpaceSQLPath),"CALLCOMBO1","FALSE"
  4803.     endif
  4804.     LibraryProcedure CurDrv, $(!DLLSQL), DlgGetCmbCurText $(DlgSpaceSQLPath),"CALLCOMBO1",""
  4805.     ifstr(i) $($4) != ""
  4806.         shell "" DoSetFreeDiskSpace $(DlgSpaceSQLPath),$(CurDrv),"TEXT2"
  4807.         set UnformattedSpace = $($R1)
  4808.         LibraryProcedure Result, $(!DLLSQL), DlgSetEditText $(DlgSpaceSQLPath),"TEXT1",$($1)
  4809.     endif
  4810.     LibraryProcedure Temp, $(!DLLSQL), StrBeforeAndAfter $(!DefInPath),"AFTER",":"
  4811.     ifstr(i) $(Temp) == ""
  4812.         set Temp = $(!DefInPath)
  4813.     endif
  4814.     LibraryProcedure Result, $(!DLLSQL), DlgSetEditText $(DlgSpaceSQLPath),"EDIT1",$(Temp)
  4815. spacesqlpath =+
  4816.     EndWait
  4817.     LibraryProcedure DLGEVENT, $(!DLLSQL), WaitEvent
  4818.     ifstr(i) $(DLGEVENT) == "CALLCOMBO1"
  4819.         LibraryProcedure CurDrv, $(!DLLSQL), DlgGetCmbCurText $(DlgSpaceSQLPath),"CALLCOMBO1",""
  4820.         ifstr(i) $($4) != ""
  4821.             shell "" DoSetFreeDiskSpace $(DlgSpaceSQLPath),$(CurDrv),"TEXT2"
  4822.             set UnformattedSpace = $($R1)
  4823.         endif
  4824.         goto spacesqlpath
  4825.     else-ifstr(i) $(DLGEVENT) == "CONTINUE"
  4826.         ifstr(i) $($4) != ""
  4827.             ifstr(i) $(!RegistryRebuild) == ""
  4828.                 ifstr(i) $(!SpaceChecking) != "OFF"
  4829.                     ifstr(i) $(UnformattedSpace) != "PLENTY"
  4830.                         LibraryProcedure MegSize, $(!DLLSQL), IntMultiply $($2),"1024","DIVIDE"
  4831.                         ifint $(UnformattedSpace) < $(MegSize)
  4832.                             read-syms STR_InsufficientDiskSpace
  4833.                             shell "" MessageError
  4834.                             goto spacesqlpath
  4835.                         endif
  4836.                     endif
  4837.                 endif
  4838.             endif
  4839.         endif
  4840.         
  4841.         LibraryProcedure PathOut, $(!DLLSQL), DlgGetEditText $(DlgSpaceSQLPath),"EDIT1"
  4842.         LibraryProcedure Temp, $(!DLLSQL), StrBeforeAndAfter $(PathOut),"AFTER",":"
  4843.         ifstr(i) $(Temp) == ""
  4844.             set Temp = $(PathOut)
  4845.         endif
  4846.         ifstr(i) $($5)  == "MASTERFORMAT_MUSTEXIST"
  4847.             LibraryProcedure Before, $(!DLLSQL), StrBeforeAndAfter $(PathOut),"LASTAFTER","\"
  4848.             ifstr(i) $(Before) == ""
  4849.                 read-syms DBNoPath$(!STF_LANGUAGE)
  4850.                 shell "" MessageError
  4851.                 goto spacesqlpath
  4852.             endif
  4853.             LibraryProcedure Before, $(!DLLSQL), StrBeforeAndAfter $(PathOut),"LASTBEFORE","\"
  4854.             LibraryProcedure After, $(!DLLSQL), StrBeforeAndAfter $(PathOut),"LASTAFTER","\"
  4855.             LibraryProcedure PathAfter, $(!DLLSQL), StrBeforeAndAfter $(After),"LASTAFTER","."
  4856.             ifstr(i) $(PathAfter) == ""
  4857.                 read-syms DBNoDat$(!STF_LANGUAGE)
  4858.                 shell "" MessageError
  4859.                 goto spacesqlpath
  4860.             endif
  4861.             LibraryProcedure Result, $(!DLLSQL), DoesFileExist $(CurDrv)$(PathOut)
  4862.             ifstr(i) $(Result) != ""
  4863.                 read-syms MasterMustExist$(!STF_LANGUAGE)
  4864.                 shell "" MessageError
  4865.                 goto spacesqlpath
  4866.             endif
  4867.             set Temp = $(Before)
  4868.             set File = $(After)
  4869.         endif
  4870.         set Status = "STATUS_SUCCESSFUL"
  4871.     else-ifstr(i) $(DLGEVENT) == "BACK"
  4872.         set Status = "STATUS_BACK"
  4873.         goto end_spacesqlpath
  4874.     else-ifstr(i) $(DLGEVENT) == "EXIT"
  4875.         shell "" QueryUserQuit $(!STF_LANGUAGE)
  4876.         ifstr(i) $($R1) == "OK"
  4877.             set Status = "STATUS_USERQUIT"
  4878.             goto end_spacesqlpath
  4879.         else
  4880.             goto spacesqlpath
  4881.         endif
  4882.     else
  4883.         goto spacesqlpath
  4884.     endif
  4885. end_spacesqlpath =+
  4886.     LibraryProcedure Result, $(!DLLSQL), CloseDialog $(DlgSpaceSQLPath)
  4887. endDoGetSpaceSQLPath =+
  4888.     Return $(Status),$(CurDrv),$(Temp),$(File)
  4889.         
  4890. [DoGetSpaceMasterPath]
  4891.     ifstr(i) $(!IniFilePath) != ""
  4892.         LibraryProcedure !MasterDBFileName, $(!DLLSQL), GetPrivProfStr "MasterPath", "MasterDBFileName", $(!IniFilePath)
  4893.         LibraryProcedure Temp, $(!DLLSQL) GetPrivProfStr "MasterPath", "MasterDBPath", $(!IniFilePath)
  4894.         LibraryProcedure !LogicalDBDrive, $(!DLLSQL), GetPrivProfStr "MasterPath", "LogicalDBDrive", $(!IniFilePath)
  4895.         set !MasterDBPath = $(!LogicalDBDrive)$(Temp)
  4896.         set !DefMasterPath = $(!MasterDBPath)"\"$(!MasterDBFileName)
  4897.         LibraryProcedure !MstrSize, $(!DLLSQL), GetPrivProfStr "MasterPath", "MasterSize", $(!IniFilePath)
  4898.         LibraryProcedure !SQLMasterSize, $(!DLLSQL), CheckStringFormat "FMT_DATABASE_SIZE",$(!MinMasterSize),$(!MstrSize)
  4899.         set Status = STATUS_SUCCESSFUL
  4900.         goto endDoGetSpaceMasterPath
  4901.     endif
  4902.     StartWait
  4903.     read-syms $($0)
  4904.     LibraryProcedure DlgSpaceMasterSQLPath, $(!DLLSQL), SQLDlgDisplay $(STF_HWND),$(DlgTemplate),"",$(!SQLDlgNames),"MODAL",""
  4905.     ifstr(i) $(!RemoteComputer) == ""
  4906.         LibraryProcedure HardDrives, $(!DLLSQL), ListDriveTypes $($3)
  4907.         ForListDo $(HardDrives)
  4908.             LibraryProcedure Result, $(!DLLSQL), DlgAddCmbEntry $(DlgSpaceMasterSQLPath),"CALLCOMBO1",$($)
  4909.         EndForListDo
  4910.         ifstr(i) $($6) != ""
  4911.             LibraryProcedure Result, $(!DLLSQL), DlgSetCmbCurSel $(DlgSpaceMasterSQLPath),"CALLCOMBO1","BYENTRY",$($6)
  4912.         else
  4913.             LibraryProcedure Result, $(!DLLSQL), DlgSetCmbCurSel $(DlgSpaceMasterSQLPath),"CALLCOMBO1","BYINDEX","0"
  4914.         endif
  4915.     else
  4916.         LibraryProcedure Result, $(!DLLSQL), DlgAddCmbEntry $(DlgSpaceMasterSQLPath),"CALLCOMBO1",$(!RemoteDBDrive)
  4917.         LibraryProcedure Result, $(!DLLSQL), DlgSetCmbCurSel $(DlgSpaceMasterSQLPath),"CALLCOMBO1","BYINDEX","0"
  4918.         LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(DlgSpaceMasterSQLPath),"CALLCOMBO1","FALSE"
  4919.     endif
  4920.     LibraryProcedure CurDrv, $(!DLLSQL), DlgGetCmbCurText $(DlgSpaceMasterSQLPath),"CALLCOMBO1",""
  4921.     ifstr(i) $($4) != ""
  4922.         shell "" DoSetFreeDiskSpace $(DlgSpaceMasterSQLPath),$(CurDrv),"TEXT2"
  4923.         set UnformattedSpace = $($R1)
  4924.         LibraryProcedure Result, $(!DLLSQL), DlgSetEditText $(DlgSpaceMasterSQLPath),"TEXT1",$($1)" "$(!MasterDBSize)
  4925.     endif
  4926.     LibraryProcedure Temp, $(!DLLSQL), StrBeforeAndAfter $(!DefMasterPath),"AFTER",":"
  4927.     ifstr(i) $(Temp) == ""
  4928.         set Temp = $(!DefMasterPath)
  4929.     endif
  4930.     LibraryProcedure Result, $(!DLLSQL), DlgSetEditText $(DlgSpaceMasterSQLPath),"EDIT1",$(Temp)
  4931. spacesqlpath =+
  4932.     EndWait
  4933.     LibraryProcedure DLGEVENT, $(!DLLSQL), WaitEvent
  4934.     ifstr(i) $(DLGEVENT) == "CALLCOMBO1"
  4935.         LibraryProcedure CurDrv, $(!DLLSQL), DlgGetCmbCurText $(DlgSpaceMasterSQLPath),"CALLCOMBO1",""
  4936.         ifstr(i) $($4) != ""
  4937.             shell "" DoSetFreeDiskSpace $(DlgSpaceMasterSQLPath),$(CurDrv),"TEXT2"
  4938.             set UnformattedSpace = $($R1)
  4939.         endif
  4940.         goto spacesqlpath
  4941.     else-ifstr(i) $(DLGEVENT) == "CONTINUE"
  4942.         LibraryProcedure PathOut, $(!DLLSQL), DlgGetEditText $(DlgSpaceMasterSQLPath),"EDIT1"
  4943.         LibraryProcedure !MstrSize, $(!DLLSQL), DlgGetEditText $(DlgSpaceMasterSQLPath),"EDIT2"
  4944.         LibraryProcedure Temp, $(!DLLSQL), StrBeforeAndAfter $(PathOut),"AFTER",":"
  4945.         ifstr(i) $(Temp) == ""
  4946.             set Temp = $(PathOut)
  4947.         endif
  4948.         
  4949.         LibraryProcedure After, $(!DLLSQL), StrBeforeAndAfter $(PathOut),"LASTAFTER","\"
  4950.         LibraryProcedure Before, $(!DLLSQL), StrBeforeAndAfter $(PathOut),"LASTBEFORE","\"
  4951.         LibraryProcedure PathAfter, $(!DLLSQL), StrBeforeAndAfter $(After),"LASTAFTER","."
  4952.         ifstr(i) $(PathAfter) == ""
  4953.             read-syms DBNoDat$(!STF_LANGUAGE)
  4954.             shell "" MessageError
  4955.             goto spacesqlpath
  4956.         endif
  4957.         
  4958.         ifstr(i) $(!RegistryRebuild) == ""
  4959.             LibraryProcedure Result, $(!DLLSQL), DoesFileExist $(CurDrv)$(PathOut)
  4960.             ifstr(i) $(Result) == ""
  4961.                 ifstr(i) $($5)  != "MASTER_DONT_CARE_EXIST"
  4962.                     read-syms MasterExists$(!STF_LANGUAGE)
  4963.                     read-syms YesNoDlg$(!STF_LANGUAGE)
  4964.                     ui start $(DlgTemplate)
  4965.                     ifstr(i) $(DLGEVENT) == "NO"
  4966.                         goto spacesqlpath
  4967.                     endif
  4968.                 endif
  4969.             endif
  4970.             LibraryProcedure Result, $(!DLLSQL), CheckStringFormat "FMT_DATABASE_SIZE",$(!MinMasterSize),$(!MstrSize)
  4971.             ifstr(i) $(Result) == "BAD_FORMAT"
  4972.                 read-syms DBSizeInvalid$(!STF_LANGUAGE)
  4973.                 shell "" MessageError
  4974.                 goto spacesqlpath
  4975.             else
  4976.                 ifstr(i) $(Result) == "TOO_SMALL"
  4977.                     read-syms DBSizeInvalid$(!STF_LANGUAGE)
  4978.                     shell "" MessageError
  4979.                     goto spacesqlpath
  4980.                 else
  4981.                     ifstr(i) $($4) != ""
  4982.                         ifstr(i) $(!SpaceChecking) != "OFF"
  4983.                             ifstr(i) $(UnformattedSpace) != "PLENTY"
  4984.                                 LibraryProcedure MasterK, $(!DLLSQL), IntMultiply $(!MstrSize),"1024"
  4985.                                 LibraryProcedure FilesK, $(!DLLSQL), IntMultiply $($2),"1024","DIVIDE"
  4986.                                 LibraryProcedure TotalK, $(!DLLSQL), IntMultiply $(MasterK),$(FilesK),"ADD"
  4987.                                 ifint $(UnformattedSpace) < $(TotalK)
  4988.                                     read-syms STR_InsufficientDiskSpace
  4989.                                     shell "" MessageError
  4990.                                     goto spacesqlpath
  4991.                                 endif
  4992.                             endif
  4993.                         endif
  4994.                     endif
  4995.                     set !SQLMasterSize = $(Result)
  4996.                 endif
  4997.             endif
  4998.         endif
  4999.         set Status = "STATUS_SUCCESSFUL"
  5000.         set !MasterDBFileName = $(After)
  5001.         ifstr(i) $(!RemoteComputer) == ""
  5002.             set !LogicalDBDrive = $(CurDrv)
  5003.             set !MasterDBPath = $(!LogicalDBDrive)$(Before)
  5004.         else
  5005.             set !MasterDBPath = $(!RemoteDBDrive)$(Before)
  5006.         endif
  5007.         set !DefMasterPath = $(!MasterDBPath)"\"$(!MasterDBFileName)
  5008.         
  5009.         set Status = "STATUS_SUCCESSFUL"
  5010.     else-ifstr(i) $(DLGEVENT) == "BACK"
  5011.         set Status = "STATUS_BACK"
  5012.         goto end_spacesqlpath
  5013.     else-ifstr(i) $(DLGEVENT) == "EXIT"
  5014.         shell "" QueryUserQuit $(!STF_LANGUAGE)
  5015.         ifstr(i) $($R1) == "OK"
  5016.             set Status = "STATUS_USERQUIT"
  5017.             goto end_spacesqlpath
  5018.         else
  5019.             goto spacesqlpath
  5020.         endif
  5021.     else
  5022.         goto spacesqlpath
  5023.     endif
  5024. end_spacesqlpath =+
  5025.     LibraryProcedure Result, $(!DLLSQL), CloseDialog $(DlgSpaceMasterSQLPath)
  5026. endDoGetSpaceMasterPath =+
  5027.     Return $(Status)
  5028.         
  5029. [DoGetUtilsAndPath]
  5030.     StartWait
  5031.     read-syms GetSpaceUtilOptsDlg
  5032.     LibraryProcedure DlgUtilPath, $(!DLLSQL), SQLDlgDisplay $(STF_HWND),$(DlgTemplate),"",$(!SQLDlgNames),"MODAL",""
  5033.     ifstr(i) $(!RemoteComputer) == ""
  5034.         LibraryProcedure HardDrives, $(!DLLSQL), ListDriveTypes "1"
  5035.         ForListDo $(HardDrives)
  5036.             LibraryProcedure Result, $(!DLLSQL), DlgAddCmbEntry $(DlgUtilPath),"CALLCOMBO1",$($)
  5037.         EndForListDo
  5038.         ifstr(i) $(!ClientInstallKey) == "TRUE"
  5039.             LibraryProcedure Result, $(!DLLSQL), DlgSetCmbCurSel $(DlgUtilPath),"CALLCOMBO1","BYENTRY",$(!ClientInstallDrive)
  5040.         else
  5041.             LibraryProcedure Result, $(!DLLSQL), DlgSetCmbCurSel $(DlgUtilPath),"CALLCOMBO1","BYINDEX","0"
  5042.         endif
  5043.     else
  5044.         LibraryProcedure Result, $(!DLLSQL), DlgAddCmbEntry $(DlgUtilPath),"CALLCOMBO1",$(!RemoteSQLDrive)
  5045.         LibraryProcedure Result, $(!DLLSQL), DlgSetCmbCurSel $(DlgUtilPath),"CALLCOMBO1","BYINDEX","0"
  5046.         LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(DlgUtilPath),"CALLCOMBO1","FALSE"
  5047.     endif
  5048.     LibraryProcedure Result, $(!DLLSQL), DlgCheckButton $(DlgUtilPath),"DLGBUTTON1","TRUE"
  5049.     LibraryProcedure Result, $(!DLLSQL), DlgCheckButton $(DlgUtilPath),"DLGBUTTON2","TRUE"
  5050.     LibraryProcedure Result, $(!DLLSQL), DlgCheckButton $(DlgUtilPath),"DLGBUTTON3","TRUE"
  5051.     LibraryProcedure Result, $(!DLLSQL), DlgCheckButton $(DlgUtilPath),"DLGBUTTON4","TRUE"
  5052.     LibraryProcedure Result, $(!DLLSQL), DlgCheckButton $(DlgUtilPath),"DLGBUTTON5","TRUE"
  5053.     LibraryProcedure Result, $(!DLLSQL), DlgCheckButton $(DlgUtilPath),"DLGBUTTON9","TRUE"
  5054.     ifstr(i) $(!RISCInst) == "YES"
  5055.         LibraryProcedure Result, $(!DLLSQL), DlgCheckButton $(DlgUtilPath),"DLGBUTTON6","FALSE"
  5056.         LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(DlgUtilPath),"DLGBUTTON6","FALSE"
  5057.         LibraryProcedure Result, $(!DLLSQL), DlgCheckButton $(DlgUtilPath),"DLGBUTTON7","FALSE"
  5058.         LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(DlgUtilPath),"DLGBUTTON7","FALSE"
  5059.         LibraryProcedure Result, $(!DLLSQL), DlgCheckButton $(DlgUtilPath),"DLGBUTTON8","FALSE"
  5060.         LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(DlgUtilPath),"DLGBUTTON8","FALSE"
  5061.     else
  5062.         LibraryProcedure Result, $(!DLLSQL), DlgCheckButton $(DlgUtilPath),"DLGBUTTON6","TRUE"
  5063.         LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(DlgUtilPath),"DLGBUTTON6","TRUE"
  5064.         LibraryProcedure Result, $(!DLLSQL), DlgCheckButton $(DlgUtilPath),"DLGBUTTON7","TRUE"
  5065.         LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(DlgUtilPath),"DLGBUTTON7","TRUE"
  5066.         LibraryProcedure Result, $(!DLLSQL), DlgCheckButton $(DlgUtilPath),"DLGBUTTON8","TRUE"
  5067.         LibraryProcedure Result, $(!DLLSQL), EnableDlgBtn $(DlgUtilPath),"DLGBUTTON8","TRUE"
  5068.     endif
  5069.     LibraryProcedure CurDrv, $(!DLLSQL), DlgGetCmbCurText $(DlgUtilPath),"CALLCOMBO1",""
  5070.     shell "" DoSetFreeDiskSpace $(DlgUtilPath),$(CurDrv),"TEXT2"
  5071.     set UnformattedSpace = $($R1)
  5072.     shell "" DoGetUtilSelectionList $(DlgUtilPath)
  5073.     set GetCost = "TRUE"
  5074.     install InstallUtilFiles
  5075.     set GetCost = ""
  5076.     LibraryProcedure Result, $(!DLLSQL), CheckStringFormat "FMT_SPACE","KILO",$(SpaceCost)
  5077.     LibraryProcedure Result, $(!DLLSQL), DlgSetEditText $(DlgUtilPath),"TEXT1",$(Result)
  5078.     LibraryProcedure Temp, $(!DLLSQL), StrBeforeAndAfter $(!DefInPath),"AFTER",":"
  5079.     ifstr(i) $(Temp) == ""
  5080.         set Temp = $(!DefInPath)
  5081.     endif
  5082.     LibraryProcedure Result, $(!DLLSQL), DlgSetEditText $(DlgUtilPath),"EDIT1",$(Temp)
  5083. spacesqlpath =+
  5084.     EndWait
  5085.     LibraryProcedure DLGEVENT, $(!DLLSQL), WaitEvent
  5086.     ifstr(i) $(DLGEVENT) == "CALLCOMBO1"
  5087.         LibraryProcedure CurDrv, $(!DLLSQL), DlgGetCmbCurText $(DlgUtilPath),"CALLCOMBO1",""
  5088.         shell "" DoSetFreeDiskSpace $(DlgUtilPath),$(CurDrv),"TEXT2"
  5089.         set UnformattedSpace = $($R1)
  5090.         goto spacesqlpath
  5091.     else-ifstr(i) $(DLGEVENT) == "CALLCOMBOKILLFOCUS1"
  5092.         goto spacesqlpath
  5093.     else-ifstr(i) $(DLGEVENT) == "CONTINUE"
  5094.         shell "" DoGetUtilSelectionList $(DlgUtilPath)
  5095.         QueryListSize NumNets $(!UtilFiles)
  5096.         ifint $(NumNets) == "0"
  5097.             read-syms NoUtils$(!STF_LANGUAGE)
  5098.             shell "" MessageError
  5099.             goto spacesqlpath
  5100.         endif
  5101.         
  5102.         ifstr(i) $(!SpaceChecking) != "OFF"
  5103.             ifstr(i) $(UnformattedSpace) != "PLENTY"
  5104.                 LibraryProcedure MegSize, $(!DLLSQL), IntMultiply $(SpaceCost),"1024","DIVIDE"
  5105.                 ifint $(UnformattedSpace) < $(MegSize)
  5106.                     read-syms STR_InsufficientDiskSpace
  5107.                     shell "" MessageError
  5108.                     goto spacesqlpath
  5109.                 endif
  5110.             endif
  5111.         endif
  5112.         
  5113.         LibraryProcedure PathOut, $(!DLLSQL), DlgGetEditText $(DlgUtilPath),"EDIT1"
  5114.         LibraryProcedure Temp, $(!DLLSQL), StrBeforeAndAfter $(PathOut),"AFTER",":"
  5115.         ifstr(i) $(Temp) == ""
  5116.             set Temp = $(PathOut)
  5117.         endif
  5118.         set Status = "STATUS_SUCCESSFUL"
  5119.     else-ifstr(i) $(DLGEVENT) == "BACK"
  5120.         set Status = "STATUS_BACK"
  5121.         goto end_spacesqlpath
  5122.     else-ifstr(i) $(DLGEVENT) == "EXIT"
  5123.         ifstr(i) $(!AllowExit) == "YES"
  5124.             shell "" QueryUserQuit $(!STF_LANGUAGE)
  5125.             ifstr(i) $($R1) == "OK"
  5126.                 set Status = "STATUS_USERQUIT"
  5127.                 goto end_spacesqlpath
  5128.             else
  5129.                 goto spacesqlpath
  5130.             endif
  5131.         endif
  5132.     else
  5133.         StartWait
  5134.         shell "" DoGetUtilSelectionList $(DlgUtilPath)
  5135.         set GetCost = "TRUE"
  5136.         ifstr(i) $($R0) == "STATUS_BACK"
  5137.             goto spacesqlpath
  5138.         else-ifstr(i) $($R0) == "STATUS_USERQUIT"
  5139.             set Status = "STATUS_USERQUIT"
  5140.             goto end_spacesqlpath
  5141.         endif
  5142.         install InstallUtilFiles
  5143.         set GetCost = ""
  5144.         LibraryProcedure Result, $(!DLLSQL), CheckStringFormat "FMT_SPACE","KILO",$(SpaceCost)
  5145.         LibraryProcedure Result, $(!DLLSQL), DlgSetEditText $(DlgUtilPath),"TEXT1",$(Result)
  5146.         EndWait
  5147.         goto spacesqlpath
  5148.     endif
  5149. end_spacesqlpath =+
  5150.     LibraryProcedure Result, $(!DLLSQL), CloseDialog $(DlgUtilPath)
  5151.     Return $(Status),$(CurDrv),$(Temp)
  5152.     
  5153. [DoGetSQLBooksInstall]
  5154.     ifstr(i) $(!IniFilePath) != ""
  5155.         set Status = "STATUS_SUCCESSFUL"
  5156.         LibraryProcedure !SQLBooksType, $(!DLLSQL), GetPrivProfStr "NewOptions", "BooksOnline", $(!IniFilePath)
  5157.         goto endDoGetSQLBooksInstall
  5158.     endif
  5159.     set Status = "STATUS_FAIL"
  5160.     StartWait
  5161.     read-syms SQLBooksOnlineDlg$(!STF_LANGUAGE)
  5162.     LibraryProcedure DlgSQLBooks, $(!DLLSQL), SQLDlgDisplay $(STF_HWND),$(DlgTemplate),"",$(!SQLDlgNames),"MODAL",""
  5163.     LibraryProcedure Result, $(!DLLSQL), DlgCheckButton $(DlgSQLBooks),"UNIBUTTON1","TRUE"
  5164.     LibraryProcedure Result, $(!DLLSQL), DlgCheckButton $(DlgSQLBooks),"UNIBUTTON2","FALSE"
  5165.     LibraryProcedure Result, $(!DLLSQL), DlgCheckButton $(DlgSQLBooks),"UNIBUTTON3","FALSE"
  5166. sqlbookenter =+
  5167.     LibraryProcedure DLGEVENT, $(!DLLSQL), WaitEvent
  5168.     ifstr(i) $(DLGEVENT) == "CONTINUE"
  5169.         set Status = "STATUS_SUCCESSFUL"
  5170.         LibraryProcedure !SQLBooksType, $(!DLLSQL), GetCheckedRadio $(DlgSQLBooks)
  5171.         goto sqlbooksdone
  5172.     else-ifstr(i) $(DLGEVENT) == "BACK"
  5173.         set Status = "STATUS_BACK"
  5174.         goto sqlbooksdone
  5175.     else-ifstr(i) $(DLGEVENT) == "EXIT"
  5176.         shell "" QueryUserQuit $(!STF_LANGUAGE)
  5177.         ifstr(i) $($R1) == "OK"
  5178.             set Status = "STATUS_USERQUIT"
  5179.         else
  5180.             goto sqlbookenter
  5181.         endif
  5182.     endif
  5183.     EndWait
  5184. sqlbooksdone =+
  5185.     LibraryProcedure Result, $(!DLLSQL), CloseDialog $(DlgSQLBooks)
  5186. endDoGetSQLBooksInstall =+
  5187.     Return $(Status)
  5188.         
  5189. [DoGetUtilSelectionList]
  5190.     set !UtilFiles = {}
  5191.     set !ODBCInstall = "NO"
  5192.     LibraryProcedure BtnState, $(!DLLSQL), IsDlgBtnChecked $($0),"DLGBUTTON1"
  5193.     ifstr(i) $(BtnState) == "CHECKED"
  5194.         set !UtilFiles = >( $(!UtilFiles), $(!BCP))
  5195.     endif
  5196.     LibraryProcedure BtnState, $(!DLLSQL), IsDlgBtnChecked $($0),"DLGBUTTON2"
  5197.     ifstr(i) $(BtnState) == "CHECKED"
  5198.         set !UtilFiles = >( $(!UtilFiles), $(!ISQL))
  5199.     endif
  5200.     LibraryProcedure BtnState, $(!DLLSQL), IsDlgBtnChecked $($0),"DLGBUTTON3"
  5201.     ifstr(i) $(BtnState) == "CHECKED"
  5202.         set !UtilFiles = >( $(!UtilFiles), $(!SQLStarfterEXE))
  5203.     endif
  5204.     LibraryProcedure BtnState, $(!DLLSQL), IsDlgBtnChecked $($0),"DLGBUTTON4"
  5205.     ifstr(i) $(BtnState) == "CHECKED"
  5206.         set !UtilFiles = >( $(!UtilFiles), $(!SQLSecManEXE))
  5207.     endif
  5208.     LibraryProcedure BtnState, $(!DLLSQL), IsDlgBtnChecked $($0),"DLGBUTTON5"
  5209.     ifstr(i) $(BtnState) == "CHECKED"
  5210.         set !UtilFiles = >( $(!UtilFiles), $(!ReadPipe))
  5211.     endif
  5212.     LibraryProcedure BtnState, $(!DLLSQL), IsDlgBtnChecked $($0),"DLGBUTTON6"
  5213.     ifstr(i) $(BtnState) == "CHECKED"
  5214.         set !UtilFiles = >( $(!UtilFiles), $(!MSQueryEXE))
  5215.         set !ODBCInstall = "YES"
  5216.     endif
  5217.     LibraryProcedure BtnState, $(!DLLSQL), IsDlgBtnChecked $($0),"DLGBUTTON7"
  5218.     ifstr(i) $(BtnState) == "CHECKED"
  5219.         set !UtilFiles = >( $(!UtilFiles), $(!WebWizardEXE))
  5220.     endif
  5221.     LibraryProcedure BtnState, $(!DLLSQL), IsDlgBtnChecked $($0),"DLGBUTTON8"
  5222.     ifstr(i) $(BtnState) == "CHECKED"
  5223.         set !UtilFiles = >( $(!UtilFiles), $(!MSDTCClientEXE))
  5224.     endif
  5225.     LibraryProcedure BtnState, $(!DLLSQL), IsDlgBtnChecked $($0),"DLGBUTTON9"
  5226.     ifstr(i) $(BtnState) == "CHECKED"
  5227.         set !UtilFiles = >( $(!UtilFiles), $(!SQLTraceEXE))
  5228.     endif
  5229.     Return
  5230.         
  5231. [DoGetPathNCopy]
  5232.     set Status = "STATUS_FAILED"
  5233. getnetpath =+
  5234.     read-syms $(!CopyPathTemplate)
  5235.     set !SQLDLGPath = $(!DefSQLDLGPath)
  5236.     shell "" DoGetPath
  5237.     ifstr(i) $($R0) == "STATUS_SUCCESSFUL"
  5238.         ifstr(i) $(!ExtraEdit) != ""
  5239.             LibraryProcedure !ExtraEditText, $(!DLLSQL), DlgGetEditText $(!DlgEdit),$(!ExtraEdit)
  5240.             ifstr(i) $(!ExtraEditText) == ""
  5241.                 set !AddlText = $(!ExtraEditFail)
  5242.                 shell "" MessageError
  5243.                 goto getnetpath
  5244.             endif
  5245.         endif
  5246.         
  5247.         LibraryProcedure Before, $(!DLLSQL), StrBeforeAndAfter $(!PathOut),"BEFORE","\"
  5248.         LibraryProcedure Type, $(!DLLSQL), GetDrvType $(Before)"\"
  5249.         ifstr(i) $(Type) == "DRIVE_REMOVEABLE"
  5250.             set !TmpDrive = $(Before)
  5251.             read-syms InsertDisk$(!STF_LANGUAGE)
  5252.             shell "" MessageError
  5253.         endif
  5254.         
  5255.         LibraryProcedure Result, $(!DLLSQL), DoesFileExist $(!PathOut)
  5256.         ifstr(i) $(Result) != ""
  5257.             read-syms FileDoesntExist$(!STF_LANGUAGE)
  5258.             shell "" MessageError
  5259.             goto getnetpath
  5260.         endif
  5261.         LibraryProcedure After, $(!DLLSQL), StrBeforeAndAfter $(!PathOut),"AFTER","\"
  5262.         ifstr(i) $(After) == ""
  5263.             read-syms FileDoesntExist$(!STF_LANGUAGE)
  5264.             shell "" MessageError
  5265.             goto getnetpath
  5266.         endif
  5267.         
  5268.         LibraryProcedure !TheStripped, $(!DLLSQL), GetStrippedFilename $(!PathOut)
  5269.         LibraryProcedure Before, $(!DLLSQL), StrBeforeAndAfter $(!PathOut),"LASTBEFORE","\"
  5270.         
  5271.         set !SrcCopyPath = $(Before)"\"
  5272.         set !DestCopyPath = $(!DestPath)
  5273.         set !OneOffFile = $(!TheStripped)
  5274.         read-syms ProgressCopyVars
  5275.         install InstallOneOffFileCopy
  5276.         ifstr(i) $(STF_INSTALL_OUTCOME) != "STF_SUCCESS"
  5277.             read-syms FileCouldNotBeCopied$(!STF_LANGUAGE)
  5278.             LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)
  5279.             goto end_getpathncopy
  5280.         endif
  5281.         set Status = "STATUS_SUCCESSFUL"
  5282.     else-ifstr(i) $($R0) == "STATUS_BACK"
  5283.         set Status = "STATUS_BACK"
  5284.     endif
  5285. end_getpathncopy =+
  5286.     LibraryProcedure Result, $(!DLLSQL), CloseDialog $(!DlgEdit)
  5287.     set !DlgEdit = ""
  5288.     Return $(Status)
  5289.     
  5290. [DoReBuild]
  5291.     set Status = "STATUS_FAILED"
  5292.     set !DlgHandle = ""
  5293.     
  5294.     ifstr(i) $(!TheSortFile) == $(!UserDefined)
  5295.         shell "" DoGetSortFileName
  5296.         ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  5297.             goto end_rebuild
  5298.         endif
  5299.     endif
  5300.     read-syms InstallingDlg$(!STF_LANGUAGE)
  5301.     LibraryProcedure !DlgHandle, $(!DLLSQL), BillBoard $(STF_HWND),"",$(!SQLDlgNames)
  5302.     StartWait
  5303.     install InstallMasterFile
  5304.     EndWait
  5305.     
  5306.     shell "" UpdateSCM $($0)
  5307.     ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  5308.         read-syms SCMError$(!STF_LANGUAGE)
  5309.         LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)
  5310.         LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$($R1)
  5311.         goto end_rebuild
  5312.     endif
  5313.     
  5314.     shell "" RegWriteSerialNumberInfo
  5315.     ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  5316.         goto end_rebuild
  5317.     endif
  5318.     
  5319.     shell "" RegWriteANSIOEM
  5320.     ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  5321.         goto end_rebuild
  5322.     endif
  5323.     
  5324.     LibraryProcedure TmpParamList, $(!DLLSQL), RegEnumKeyValues "\\"$(!ComputerName),$(!RegSQLServerServer)"\"$(!RegSQLSvrParam),"VALUEDATA"
  5325.     QueryListSize NumArgs $(TmpParamList)
  5326.     LibraryProcedure !OpenParamKey, $(!DLLSQL), RegMakeKey "\\"$(!ComputerName),$(!RegSQLServerServer),$(!RegSQLSvrParam),$(!AdminACL)
  5327.     LibraryProcedure Result, $(!DLLSQL), RegSet $(!OpenParamKey),$(!RegValParameter)$(NumArgs),$(!RegTypeString),$(!TraceSQLKeyDB),""
  5328.     set !RegValSQL95KeyDB = $(!RegValParameter)$(NumArgs)
  5329.     LibraryProcedure Result, $(!DLLSQL), RegClose $(!OpenParamKey)
  5330.     
  5331.     set TmpParamList = {}
  5332.     LibraryProcedure TmpParamList, $(!DLLSQL), RegEnumKeyValues "\\"$(!ComputerName),$(!RegSQLServerServer)"\"$(!RegSQLSvrParam),"VALUEDATA"
  5333.     QueryListSize NumArgs $(TmpParamList)
  5334.     LibraryProcedure !OpenParamKey, $(!DLLSQL), RegMakeKey "\\"$(!ComputerName),$(!RegSQLServerServer),$(!RegSQLSvrParam),$(!AdminACL)
  5335.     LibraryProcedure Result, $(!DLLSQL), RegSet $(!OpenParamKey),$(!RegValParameter)$(NumArgs),$(!RegTypeString),$(!SingleUserMode),""
  5336.     set !RegValSingleUserArg = $(!RegValParameter)$(NumArgs)
  5337.     LibraryProcedure Result, $(!DLLSQL), RegClose $(!OpenParamKey)
  5338.  
  5339.     read-syms BillboardRunningNConnSQL$(!STF_LANGUAGE)
  5340.     LibraryProcedure Result, $(!DLLSQL), UpdateBillboard $(!DlgHandle),$(!BillName)
  5341.     
  5342.     shell "" StartService $(!SQLServerService)
  5343.     ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  5344.         goto end_rebuild
  5345.     endif
  5346.     
  5347.     
  5348.     LibraryProcedure Result, $(!DLLSQL), SQLLogin $(!LoginSleepPeriod),$(!LoginSleepRetrys),$(!ServerName),$(!SALogin),$(!SAPassword)
  5349.     ifstr(i) $(Result) == "NO_SERVER"
  5350.         read-syms NoLoginToSQLServer$(!STF_LANGUAGE)
  5351.         LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)
  5352.         goto end_rebuild
  5353.     endif
  5354.     
  5355.     LibraryProcedure Result, $(!DLLSQL), SQLLogout
  5356.     
  5357.     ifint $(!MstrSize) > "25"
  5358.         shell "" ExpandMaster
  5359.         ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  5360.             goto end_rebuild
  5361.         endif
  5362.     endif
  5363.     
  5364.     ifstr(i) $(!TheSortFile) != $(!DefaultSort)
  5365.         read-syms BillboardCharset$(!STF_LANGUAGE)
  5366.         LibraryProcedure Result, $(!DLLSQL), UpdateBillboard $(!DlgHandle),$(!BillName)
  5367.         StartWait
  5368.         ProcessExecute Result,"WAIT",$(!SQLPath)"\"$(!Binaries)"\"$(!CharSet)" /S"$(!ServerName)" /P /o"$(!SQLPath)"\"$(!InstallDir)"\"$(!CharSetOut)" /L"$(!TheCharSetPath)" "$(!TheSortFile)
  5369.         EndWait
  5370.         ifstr(i) $(Result) == "PROCESS_ERROR"
  5371.             read-syms ProcessExecError$(!STF_LANGUAGE)
  5372.             LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!CharSet)" "$(!AddlText)
  5373.             goto end_rebuild
  5374.         else-ifstr(i) $(Result) != "0"
  5375.             read-syms ProcessRetError$(!STF_LANGUAGE)
  5376.             LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!CharSet)" "$(!AddlText)" "$(Result)
  5377.             goto end_rebuild
  5378.         endif
  5379.         shell "" UpdateSystemTables
  5380.         ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  5381.             goto end_rebuild
  5382.         endif
  5383.         shell "" StopService $(!SQLServerService)
  5384.         ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  5385.             goto end_rebuild
  5386.         endif
  5387.         read-syms BillboardIndexing$(!STF_LANGUAGE)
  5388.         LibraryProcedure Result, $(!DLLSQL), UpdateBillboard $(!DlgHandle),$(!BillName)
  5389.         shell "" ReIndexServer
  5390.         ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  5391.             goto end_rebuild
  5392.         endif
  5393.     endif
  5394.     read-syms BillboardInstScripts$(!STF_LANGUAGE)
  5395.     LibraryProcedure Result, $(!DLLSQL), UpdateBillboard $(!DlgHandle),$(!BillName)
  5396.     shell "" CreateConfig ""
  5397.     ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  5398.         goto end_rebuild
  5399.     endif
  5400.     
  5401.     ifstr(i) $(!TheSortFile) != $(!DefaultSort)
  5402.         shell "" InstallScripts
  5403.         ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  5404.             goto end_rebuild
  5405.         endif
  5406.     else
  5407.         shell "" BuildMSDB
  5408.         StartWait
  5409.         LibraryProcedure Before, $(!DLLSQL), StrBeforeAndAfter $(!InstSch),"BEFORE","."
  5410.         ProcessExecute Result,"WAIT",$(!SQLPath)"\"$(!Binaries)"\"$(!ISQL)" /n /S"$(!ServerName)" /Usa /i"$(!SQLPath)"\"$(!InstallDir)"\"$(!InstSch)" /o"$(!SQLPath)"\"$(!InstallDir)"\"$(Before)".OUT /P"
  5411.         EndWait
  5412.         ifstr(i) $(Result) == "PROCESS_ERROR"
  5413.             read-syms ProcessExecError$(!STF_LANGUAGE)
  5414.             LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!ISQL)" "$(!AddlText)
  5415.             goto noschedule
  5416.         endif
  5417.         LibraryProcedure Before, $(!DLLSQL), StrBeforeAndAfter $(!InstSmsg),"BEFORE","."
  5418.         ProcessExecute Result,"WAIT",$(!SQLPath)"\"$(!Binaries)"\"$(!ISQL)" /n /S"$(!ServerName)" /Usa /i"$(!SQLPath)"\"$(!InstallDir)"\"$(!InstSmsg)" /o"$(!SQLPath)"\"$(!InstallDir)"\"$(Before)".OUT /P"
  5419.         EndWait
  5420.         ifstr(i) $(Result) == "PROCESS_ERROR"
  5421.             read-syms ProcessExecError$(!STF_LANGUAGE)
  5422.             LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!ISQL)" "$(!AddlText)
  5423.             goto noschedule
  5424.         endif
  5425.         LibraryProcedure Before, $(!DLLSQL), StrBeforeAndAfter $(!InstConfig),"BEFORE","."
  5426.         ProcessExecute Result,"WAIT",$(!SQLPath)"\"$(!Binaries)"\"$(!ISQL)" /n /S"$(!ServerName)" /Usa /i"$(!SQLPath)"\"$(!InstallDir)"\"$(!InstConfig)" /o"$(!SQLPath)"\"$(!InstallDir)"\"$(Before)".OUT /P"
  5427.         EndWait
  5428.         ifstr(i) $(Result) == "PROCESS_ERROR"
  5429.             read-syms ProcessExecError$(!STF_LANGUAGE)
  5430.             LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!ISQL)" "$(!AddlText)
  5431.             goto noschedule
  5432.         endif
  5433.     endif
  5434.     
  5435.     shell "" InstallWEBProc
  5436.     ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  5437.         goto noschedule
  5438.     endif
  5439.  
  5440.     ifstr(i) $(!IniFilePath) != ""
  5441.         LibraryProcedure !CustomScripts, $(!DLLSQL), GetPrivProfStr "Scripts", "CustomScriptList", $(!IniFilePath)
  5442.         ifstr(i) $(!CustomScripts) != ""
  5443.             LibraryProcedure !CustScPath, $(!DLLSQL), GetPrivProfStr "Scripts", "CustScPath", $(!IniFilePath)
  5444.         endif
  5445.         ifstr(i) $(!CustomScripts) != ""
  5446.             ForListDo $(!CustomScripts)
  5447.                 StartWait
  5448.                 LibraryProcedure Before, $(!DLLSQL), StrBeforeAndAfter $($),"BEFORE","."
  5449.                 ProcessExecute Result,"WAIT",$(!SQLPath)"\"$(!Binaries)"\"$(!ISQL)" /n /S"$(!ServerName)" /Usa /i"$(!CustScPath)"\"$($)" /o"$(!SQLPath)"\"$(!InstallDir)"\"$(Before)".OUT /P"
  5450.                 EndWait
  5451.                 ifstr(i) $(Result) == "PROCESS_ERROR"
  5452.                     read-syms ProcessExecError$(!STF_LANGUAGE)
  5453.                     LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!ISQL)" "$(!AddlText)
  5454.                     goto noschedule
  5455.                 endif
  5456.             EndForListDo
  5457.         endif
  5458.     endif
  5459.     
  5460. noschedule =+
  5461.     ifstr(i) $(!Locale) != ""
  5462.         shell "" DoLangInst $(!Locale),"","CHECKED"
  5463.         ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  5464.             goto end_rebuild
  5465.         endif
  5466.     endif
  5467.     
  5468.     shell "" CheckInstallSuccess "FALSE"
  5469.     
  5470.     ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  5471.         goto end_rebuild
  5472.     endif
  5473.     set Status = "STATUS_SUCCESSFUL"
  5474.     ifstr(i) $(!RegValSQL95KeyDB) != ""
  5475.         LibraryProcedure OpenParamKey, $(!DLLSQL), RegMakeKey "\\"$(!ComputerName),$(!RegSQLServer)"\"$(!RegSQLServerSvr),$(!RegSQLSvrParam),$(!AdminACL)
  5476.         LibraryProcedure Result, $(!DLLSQL), RegDelValue $(OpenParamKey),$(!RegValSQL95KeyDB)
  5477.         LibraryProcedure Result, $(!DLLSQL), RegClose $(OpenParamKey)
  5478.     endif
  5479.     ifstr(i) $(!RegValSingleUserArg) != ""
  5480.         LibraryProcedure !OpenParamKey, $(!DLLSQL), RegMakeKey "\\"$(!ComputerName),$(!RegSQLServerServer),$(!RegSQLSvrParam),$(!AdminACL)
  5481.         LibraryProcedure Result, $(!DLLSQL), RegDelValue $(!OpenParamKey),$(!RegValSingleUserArg)
  5482.         LibraryProcedure Result, $(!DLLSQL), RegClose $(!OpenParamKey)
  5483.     endif
  5484.  
  5485. end_rebuild =+
  5486.     shell "" StopService $(!SQLServerService)
  5487.     ifstr(i) $(!DlgHandle) != ""
  5488.         LibraryProcedure Result, $(!DLLSQL), CloseDialog $(!DlgHandle)
  5489.     endif
  5490.     Return $(Status)
  5491.     
  5492. [DoGetNetLibPath]
  5493.     set Status = "STATUS_FAILED"
  5494.     set !CopyPathTemplate = GetNetLibPathDlg$(!STF_LANGUAGE)
  5495.     set !DestPath = $(!SQLPath)"\"$(!Binaries)
  5496.     shell "" DoGetPathNCopy
  5497.     set Status = $($R0)
  5498.     ifstr(i) $(Status) == "STATUS_SUCCESSFUL"
  5499.         LibraryProcedure !UserNetLib, $(!DLLSQL), StrBeforeAndAfter $(!TheStripped),"BEFORE","."
  5500.     endif
  5501.     Return $(Status)
  5502.     
  5503. [DoGetSortFileName]
  5504.     set Status = "STATUS_FAILED"
  5505.     set !CopyPathTemplate = GetSortFileDlg$(!STF_LANGUAGE)
  5506.     set !DestPath = $(!SQLPath)"\"$(!CharSets)
  5507.     shell "" DoGetPathNCopy
  5508.     ifstr(i) $($R0) == "STATUS_SUCCESSFUL"
  5509.         set Status = "STATUS_SUCCESSFUL"
  5510.         set !TheCharSetPath = $(!SQLPath)"\"$(!CharSets)
  5511.         set !TheSortFile = $(!TheStripped)
  5512.         set !TheSortConfigValue = $(!ExtraEditText)
  5513.     endif
  5514.     Return $(Status)
  5515.     
  5516. [DoGetSAPassword]
  5517.     set !AllowExit = "YES"
  5518.     set Status = "STATUS_FAILED"
  5519.     ifstr(i) $(!DlgEdit) == ""
  5520.         read-syms GetSAPasswordDlg$(!STF_LANGUAGE)
  5521.         set !SAPassword = ""
  5522.         LibraryProcedure !DlgEdit, $(!DLLSQL), SQLDlgDisplay $(STF_HWND),$(DlgTemplate),"",$(!SQLDlgNames),"",""
  5523.     endif
  5524.     getsapass = +
  5525.     LibraryProcedure DLGEVENT, $(!DLLSQL), WaitEvent
  5526.     ifstr(i) $(DLGEVENT) == "EXIT"
  5527.         ifstr(i) $(!AllowExit) == "YES"
  5528.             shell "" QueryUserQuit $(!STF_LANGUAGE)
  5529.             ifstr(i) $($R1) == "OK"
  5530.                 set Status = "STATUS_USERQUIT"
  5531.             else
  5532.                 goto getsapass
  5533.             endif
  5534.         else
  5535.             set Status = STATUS_CANCEL
  5536.         endif
  5537.     else-ifstr(i) $(DLGEVENT) == "BACK"
  5538.         set Status = "STATUS_BACK"
  5539.     else-ifstr(i) $(DLGEVENT) == "CONTINUE"
  5540.         LibraryProcedure EditTextOut1, $(!DLLSQL), DlgGetEditText $(!DlgEdit),"EDIT1"
  5541.         LibraryProcedure EditTextOut2, $(!DLLSQL), DlgGetEditText $(!DlgEdit),"EDIT2"
  5542.         ifstr(i) $(EditTextOut1) != $(EditTextOut2)
  5543.             read-syms PasswordsDontMatch$(!STF_LANGUAGE)
  5544.             shell "" MessageError
  5545.             goto getsapass
  5546.         endif
  5547.         set Status = "STATUS_SUCCESSFUL"
  5548.         set !SAPassword = $(EditTextOut1)
  5549.     endif
  5550.     ifstr(i) $(!AutoPopoff) == "YES"
  5551.         LibraryProcedure Result, $(!DLLSQL), CloseDialog $(!DlgEdit)
  5552.         set !DlgEdit = ""
  5553.     endif
  5554.     Return $(Status)
  5555.         
  5556. [DoGetMailInfo]
  5557.     set Status = "STATUS_FAILED"
  5558.     ifstr(i) $(!DlgEdit) == ""
  5559.         read-syms GetMailInfoDlg$(!STF_LANGUAGE)
  5560.         set !CopyMailInfo = ""
  5561.         LibraryProcedure !DlgEdit, $(!DLLSQL), SQLDlgDisplay $(STF_HWND),$(DlgTemplate),"",$(!SQLDlgNames),"",""
  5562.         LibraryProcedure Result, $(!DLLSQL), DlgCheckButton $(!DlgEdit),"UNIBUTTON1","TRUE"
  5563.         LibraryProcedure Result, $(!DLLSQL), DlgSetEditText $(!DlgEdit),"EDIT1",$(!MSMailUser)
  5564.         LibraryProcedure Result, $(!DLLSQL), DlgSetEditText $(!DlgEdit),"EDIT2",$(!MSMailPwd)
  5565.         LibraryProcedure Result, $(!DLLSQL), DlgSetEditText $(!DlgEdit),"EDIT3",$(!MSMailPwd)
  5566.     endif
  5567.     
  5568.     getmailinfo = +
  5569.     LibraryProcedure DLGEVENT, $(!DLLSQL), WaitEvent
  5570.     ifstr(i) $(DLGEVENT) == "EXIT"
  5571.         ifstr(i) $(!AllowExit) == "YES"
  5572.             shell "" QueryUserQuit $(!STF_LANGUAGE)
  5573.             ifstr(i) $($R1) == "OK"
  5574.                 set Status = "STATUS_USERQUIT"
  5575.             else
  5576.                 goto getmailinfo
  5577.             endif
  5578.         else
  5579.             set Status = STATUS_CANCEL
  5580.         endif
  5581.     else-ifstr(i) $(DLGEVENT) == "BACK"
  5582.         set Status = "STATUS_BACK"
  5583.     else-ifstr(i) $(DLGEVENT) == "CONTINUE"
  5584.         LibraryProcedure EditTextOut1, $(!DLLSQL), DlgGetEditText $(!DlgEdit),"EDIT1"
  5585.         LibraryProcedure EditTextOut2, $(!DLLSQL), DlgGetEditText $(!DlgEdit),"EDIT2"
  5586.         LibraryProcedure EditTextOut3, $(!DLLSQL), DlgGetEditText $(!DlgEdit),"EDIT3"
  5587.         ifstr(i) $(EditTextOut2) != $(EditTextOut3)
  5588.             read-syms PasswordsDontMatch$(!STF_LANGUAGE)
  5589.             shell "" MessageError
  5590.             goto getmailinfo
  5591.         endif
  5592.         LibraryProcedure !CopyMailInfo, $(!DLLSQL), IsDlgBtnChecked $(!DlgEdit),"UNIBUTTON1"
  5593.         set Status = "STATUS_SUCCESSFUL"
  5594.         set !MSMailUser = $(EditTextOut1)
  5595.         set !MSMailPwd = $(EditTextOut2)
  5596.     else
  5597.         goto getmailinfo
  5598.     endif
  5599.     ifstr(i) $(!AutoPopoff) == "YES"
  5600.         LibraryProcedure Result, $(!DLLSQL), CloseDialog $(!DlgEdit)
  5601.         set !DlgEdit = ""
  5602.     endif
  5603.     Return $(Status)
  5604.     
  5605. [DoGetStreetName]
  5606.     ifstr(i) $(!IniFilePath) != ""
  5607.         LibraryProcedure !StreetName, $(!DLLSQL), GetPrivProfStr "Network", "VinesStreetName", $(!IniFilePath)
  5608.         set Status = "STATUS_SUCCESSFUL"
  5609.     else
  5610.         set Status = "STATUS_FAILED"
  5611.         read-syms GetStreetNameDlg$(!STF_LANGUAGE)
  5612.         shell "" DoGetPath
  5613.         set Status = $($R0)
  5614.         ifstr(i) $(Status) == "STATUS_SUCCESSFUL"
  5615.             set !StreetName = $(!PathOut)
  5616.         endif
  5617.     endif
  5618.     Return $(Status)
  5619.     
  5620. [DoGetMultiProtEn]
  5621.     ifstr(i) $(!IniFilePath) != ""
  5622.         LibraryProcedure Temp, $(!DLLSQL), GetPrivProfStr "Network", "MultiProtEncrypt", $(!IniFilePath)
  5623.         ifstr(i) $(Temp) == "CHECKED"
  5624.             set !MultiProtEncrypt = $(!RegValEncrypt)
  5625.         else
  5626.             set !MultiProtEncrypt = ""
  5627.         endif
  5628.         set Status = "STATUS_SUCCESSFUL"
  5629.         goto endDoGetMultiProtEn
  5630.     endif
  5631.     read-syms GetMultiProtEncryptDlg$(!STF_LANGUAGE)
  5632.     set Status = "STATUS_FAILED"
  5633.     LibraryProcedure DlgChk, $(!DLLSQL), SQLDlgDisplay $(STF_HWND),$(DlgTemplate),"",$(!SQLDlgNames),"",""
  5634.     ifstr(i) $(!MultiProtEncrypt) == $(!RegValEncrypt)
  5635.         set BtnState = "TRUE"
  5636.     else
  5637.         set BtnState = "FALSE"
  5638.     endif
  5639.     LibraryProcedure Result, $(!DLLSQL), DlgCheckButton $(DlgChk),"DLGBUTTON1",$(BtnState)
  5640. getMPEN =+
  5641.     LibraryProcedure DLGEVENT, $(!DLLSQL), WaitEvent
  5642.     ifstr(i) $(DLGEVENT) == "EXIT"
  5643.         ifstr(i) $(!AllowExit) == "YES"
  5644.             shell "" QueryUserQuit $(!STF_LANGUAGE)
  5645.             ifstr(i) $($R1) == "OK"
  5646.                 set Status = "STATUS_USERQUIT"
  5647.             else
  5648.                 goto getMPEN
  5649.             endif
  5650.         else
  5651.             set Status = STATUS_CANCEL
  5652.         endif
  5653.     else-ifstr(i) $(DLGEVENT) == "DLGBUTTON1"
  5654.         goto getMPEN
  5655.     else-ifstr(i) $(DLGEVENT) == "BACK"
  5656.         set Status = "STATUS_BACK"
  5657.     else-ifstr(i) $(DLGEVENT) == "CONTINUE"
  5658.         LibraryProcedure Temp, $(!DLLSQL), IsDlgBtnChecked $(DlgChk),"DLGBUTTON1"
  5659.         ifstr(i) $(Temp) == "CHECKED"
  5660.             set !MultiProtEncrypt = $(!RegValEncrypt)
  5661.         else
  5662.             set !MultiProtEncrypt = ""
  5663.         endif
  5664.         set Status = "STATUS_SUCCESSFUL"
  5665.     endif
  5666.     LibraryProcedure Result, $(!DLLSQL), CloseDialog $(DlgChk)
  5667. endDoGetMultiProtEn =+
  5668.     Return $(Status)
  5669.     
  5670. [DoGetNamedPipes]
  5671.     ifstr(i) $(!IniFilePath) != ""
  5672.         LibraryProcedure !ServerNMPipeName, $(!DLLSQL), GetPrivProfStr "Network", "ServerNMPipe", $(!IniFilePath)
  5673.         set Status = "STATUS_SUCCESSFUL"
  5674.     else
  5675.         set Status = "STATUS_FAILED"
  5676.         read-syms GetNamedPipesDlg$(!STF_LANGUAGE)
  5677.         shell "" DoGetPath
  5678.         set Status = $($R0)
  5679.         ifstr(i) $(Status) == "STATUS_SUCCESSFUL"
  5680.             set !ServerNMPipeName = $(!PathOut)
  5681.         endif
  5682.     endif
  5683.     Return $(Status)
  5684.     
  5685. [DoGetTCPIPSocket]
  5686.     ifstr(i) $(!IniFilePath) != ""
  5687.         LibraryProcedure !TCPIPSocketNumber, $(!DLLSQL), GetPrivProfStr "Network", "TCPIPSocketNumber", $(!IniFilePath)
  5688.         set Status = "STATUS_SUCCESSFUL"
  5689.     else
  5690.         set Status = "STATUS_FAILED"
  5691.         read-syms GetTCPIPSocketDlg$(!STF_LANGUAGE)
  5692.         shell "" DoGetPath
  5693.         set Status = $($R0)
  5694.         ifstr(i) $(Status) == "STATUS_SUCCESSFUL"
  5695.             set !TCPIPSocketNumber = $(!PathOut)
  5696.         endif
  5697.     endif
  5698.     Return $(Status)
  5699.     
  5700. [DoGetServiceName]
  5701.     ifstr(i) $(!IniFilePath) != ""
  5702.         LibraryProcedure !ServiceName, $(!DLLSQL), GetPrivProfStr "Network", "SPXServiceName", $(!IniFilePath)
  5703.         set Status = "STATUS_SUCCESSFUL"
  5704.     else
  5705.         set Status = "STATUS_FAILED"
  5706.         read-syms GetServiceNameDlg$(!STF_LANGUAGE)
  5707.         shell "" DoGetPath
  5708.         set Status = $($R0)
  5709.         ifstr(i) $(Status) == "STATUS_SUCCESSFUL"
  5710.             set !ServiceName = $(!PathOut)
  5711.         endif
  5712.     endif
  5713.     Return $(Status)
  5714.     
  5715. [DoGetADSPService]
  5716.     ifstr(i) $(!IniFilePath) != ""
  5717.         LibraryProcedure !ADSPServiceName, $(!DLLSQL), GetPrivProfStr "Network", "ADSPObjectName", $(!IniFilePath)
  5718.         set Status = "STATUS_SUCCESSFUL"
  5719.     else
  5720.         set Status = "STATUS_FAILED"
  5721.         read-syms GetADSPNameDlg$(!STF_LANGUAGE)
  5722.         shell "" DoGetPath
  5723.         set Status = $($R0)
  5724.         ifstr(i) $(Status) == "STATUS_SUCCESSFUL"
  5725.             set !ADSPServiceName = $(!PathOut)
  5726.         endif
  5727.     endif
  5728.     Return $(Status)
  5729.     
  5730. [DoGetDECNetObjectID]
  5731.     ifstr(i) $(!IniFilePath) != ""
  5732.         LibraryProcedure !DecNetObjectID, $(!DLLSQL), GetPrivProfStr "Network", "DecNetObjectID", $(!IniFilePath)
  5733.         set Status = "STATUS_SUCCESSFUL"
  5734.     else
  5735.         set Status = "STATUS_FAILED"
  5736.         read-syms GetDECNetNameDlg$(!STF_LANGUAGE)
  5737.         shell "" DoGetPath
  5738.         set Status = $($R0)
  5739.         ifstr(i) $(Status) == "STATUS_SUCCESSFUL"
  5740.             set !DECNetObjectID = $(!PathOut)
  5741.         endif
  5742.     endif
  5743.     Return $(Status)
  5744.     
  5745. [DoGetGenericNetAddress]
  5746.     set Status = "STATUS_FAILED"
  5747.     read-syms GetNetAddressDlg$(!STF_LANGUAGE)
  5748.     shell "" DoGetPath
  5749.     set Status = $($R0)
  5750.     ifstr(i) $(Status) == "STATUS_SUCCESSFUL"
  5751.         set !NetAddress = $(!PathOut)
  5752.     endif
  5753.     Return $(Status)
  5754.     
  5755. [DoCreateDirectory]
  5756.     read-syms YesNoDlg$(!STF_LANGUAGE)
  5757.     ui start $(DlgTemplate)
  5758.     ifstr(i) $(DLGEVENT) == "YES"
  5759.         set Status = STATUS_YES
  5760.     else
  5761.         set Status = STATUS_NO
  5762.     endif
  5763.     Return $(Status)
  5764.     
  5765. [MessageError]
  5766.     set Status = "STATUS_FAILED"
  5767.     read-syms InfoMessage$(!STF_LANGUAGE)
  5768.     ui start $(DlgTemplate)
  5769.     Return $(Status)
  5770.     
  5771. [DoCharSet]
  5772.     ifstr(i) $(!IniFilePath) != ""
  5773.         LibraryProcedure !TheCharSet, $(!DLLSQL), GetPrivProfStr "CharSet", "CharSet", $(!IniFilePath)
  5774.         set Status = STATUS_OK
  5775.         goto endDoCharSet
  5776.     endif
  5777.     StartWait
  5778.     set Status = STATUS_CANCEL
  5779.     ifstr(i) $(!AllowExit) == "YES"
  5780.         set TheCharList = $(!CharSetUserSelList)
  5781.     else
  5782.         set TheCharList = $(!CharSetSelList)
  5783.     endif
  5784.     set ListIdx = 0
  5785.     ForListDo $(TheCharList)
  5786.         set-sub LoopIdx = $(#),1
  5787.         LibraryProcedure Idx, $(!DLLSQL), IntMultiply $(LoopIdx),2
  5788.         set-add Idx = $(Idx),2
  5789.         set TheCharIdx = *( $(TheCharList), $(Idx) )
  5790.         ifstr(i) $(TheCharIdx) == $(!TheCharSet)
  5791.             goto doneLoop
  5792.         else
  5793.             set-add ListIdx = $(ListIdx),1
  5794.         endif
  5795.     EndForListDo
  5796. doneLoop =+
  5797.     set DefListItem = $(ListIdx)
  5798.     read-syms CharSetsDlg$(!STF_LANGUAGE)
  5799.     LibraryProcedure DlgCharSets, $(!DLLSQL), SQLDlgDisplay $(STF_HWND),$(DlgTemplate),"",$(!SQLDlgNames),"2",$(TheCharList)
  5800. dosetsel =+
  5801.     EndWait
  5802.     LibraryProcedure DLGEVENT, $(!DLLSQL), WaitEvent
  5803.     ifstr(i) $(DLGEVENT) == "CONTINUE"
  5804.         set Status = STATUS_OK
  5805.         set SortType = "Normal"
  5806.         LibraryProcedure CharRetList, $(!DLLSQL), ExtractListSet $(DlgCharSets),"1"
  5807.         set !TheCharSet = *( $(CharRetList),2 )
  5808.         ifstr(i) $(!TheCharSet) == "cpISO"
  5809.             set !SortOrderSelList = $(!SortISOSelList)
  5810.         else-ifstr(i) $(!TheCharSet) == "cp850"
  5811.             set !SortOrderSelList = $(!Sort850SelList)
  5812.         else-ifstr(i) $(!TheCharSet) == "cp437"
  5813.             set !SortOrderSelList = $(!Sort437SelList)
  5814.         else-ifstr(i) $(!TheCharSet) == "cp1250"
  5815.             set !SortOrderSelList = $(!Sort1250SelList)
  5816.         else-ifstr(i) $(!TheCharSet) == "cp1251"
  5817.             set !SortOrderSelList = $(!Sort1251SelList)
  5818.         else-ifstr(i) $(!TheCharSet) == "cp1253"
  5819.             set !SortOrderSelList = $(!Sort1253SelList)
  5820.         else-ifstr(i) $(!TheCharSet) == "cp1254"
  5821.             set !SortOrderSelList = $(!Sort1254SelList)
  5822.         else-ifstr(i) $(!TheCharSet) == "cp1255"
  5823.             set !SortOrderSelList = $(!Sort1255SelList)
  5824.         else-ifstr(i) $(!TheCharSet) == "cp1256"
  5825.             set !SortOrderSelList = $(!Sort1256SelList)
  5826.         else-ifstr(i) $(!TheCharSet) == "cp1257"
  5827.             set !SortOrderSelList = $(!Sort1257SelList)
  5828.         else
  5829.             set SortType = "Defined"
  5830.         endif
  5831.         ifstr(i) $(SortType) != "Normal"
  5832.             set !TheSortFile = $(!TheCharSet)
  5833.             set !TheSortConfigValue = "0"
  5834.         else
  5835.             LibraryProcedure Idx, $(!DLLSQL), IntMultiply $(!DefSortFileIndex),3
  5836.             set !TheSortConfigValue = *( $(!SortOrderSelList), $(Idx) )
  5837.             set-sub Idx = $(Idx),1
  5838.             set !TheSortFile = *( $(!SortOrderSelList), $(Idx) )
  5839.         endif
  5840.     else-ifstr(i) $(DLGEVENT) == "BACK"
  5841.         set Status = "STATUS_BACK"
  5842.         goto end_docharset
  5843.     else-ifstr(i) $(DLGEVENT) == "EXIT"
  5844.     endif
  5845. end_docharset =+
  5846.     LibraryProcedure Result, $(!DLLSQL), CloseDialog $(DlgCharSets)
  5847. endDoCharSet =+
  5848.     Return $(Status)
  5849.     
  5850. [DoSortOrder]
  5851.     ifstr(i) $(!IniFilePath) != ""
  5852.         LibraryProcedure !TheSortFile, $(!DLLSQL), GetPrivProfStr "SortOrder", "SortFileName", $(!IniFilePath)
  5853.         LibraryProcedure !TheSortConfigValue $(!DLLSQL), GetPrivProfStr "SortOrder", "SortConfigValue", $(!IniFilePath)
  5854.         set Status = STATUS_OK
  5855.         goto endDoSortOrder
  5856.     endif
  5857.     StartWait
  5858.     set Status = STATUS_CANCEL
  5859.     set ListIdx = 0
  5860.     ForListDo $(!SortOrderSelList)
  5861.         set-sub LoopIdx = $(#),1
  5862.         LibraryProcedure Idx, $(!DLLSQL), IntMultiply $(LoopIdx),3
  5863.         set-add Idx = $(Idx),2
  5864.         set TheSortIdx = *( $(!SortOrderSelList), $(Idx) )
  5865.         ifstr(i) $(TheSortIdx) == $(!TheSortFile)
  5866.             goto doneLoop
  5867.         else
  5868.             set-add ListIdx = $(ListIdx),1
  5869.         endif
  5870.     EndForListDo
  5871. doneLoop =+
  5872.     set DefListItem = $(ListIdx)
  5873.     read-syms SortOrderDlg$(!STF_LANGUAGE)
  5874.     LibraryProcedure DlgSortOrder, $(!DLLSQL), SQLDlgDisplay $(STF_HWND),$(DlgTemplate),"",$(!SQLDlgNames),"3",$(!SortOrderSelList)
  5875. dosortsel =+
  5876.     EndWait
  5877.     LibraryProcedure DLGEVENT, $(!DLLSQL), WaitEvent
  5878.     ifstr(i) $(DLGEVENT) == "CONTINUE"
  5879.         set Status = STATUS_OK
  5880.         LibraryProcedure SortRetList, $(!DLLSQL), ExtractListSet $(DlgSortOrder),"1"
  5881.         set !TheSortFile = *( $(SortRetList), 2)
  5882.         set !TheSortConfigValue = *( $(SortRetList), 3 )
  5883.     else-ifstr(i) $(DLGEVENT) == "BACK"
  5884.         set Status = "STATUS_BACK"
  5885.         goto end_dosortorder
  5886.     else-ifstr(i) $(DLGEVENT) == "EXIT"
  5887.     endif
  5888. end_dosortorder =+
  5889.     LibraryProcedure Result, $(!DLLSQL), CloseDialog $(DlgSortOrder)
  5890. endDoSortOrder =+
  5891.     Return $(Status)
  5892.     
  5893. [DoLanguage]
  5894.     set Status = STATUS_CANCEL
  5895.     read-syms LanguageDlg$(!STF_LANGUAGE)
  5896.     LibraryProcedure DlgLanguage, $(!DLLSQL), SQLDlgDisplay $(STF_HWND),$(DlgTemplate),"",$(!SQLDlgNames),"2",$(!LangSelList)
  5897.     LibraryProcedure DLGEVENT, $(!DLLSQL), WaitEvent
  5898.     ifstr(i) $(DLGEVENT) == "CONTINUE"
  5899.         set Status = STATUS_OK
  5900.     endif
  5901.     LibraryProcedure Result, $(!DLLSQL), CloseDialog $(DlgLanguage)
  5902.     Return $(Status)
  5903.     
  5904. [DoNetwork]
  5905.     ifstr(i) $(!IniFilePath) != ""
  5906.         LibraryProcedure !NetLibList, $(!DLLSQL), GetPrivProfStr "Network", "NetLibList", $(!IniFilePath)
  5907.         set Status = STATUS_OK
  5908.         goto endDoNetwork
  5909.     endif
  5910.     StartWait
  5911.     set Status = STATUS_CANCEL
  5912.     set DefListItems = {}
  5913.     set TheCheckIdx = 0
  5914.     ForListDo $(!NetworkSelList)
  5915.         set-sub LoopIdx = $(#),1
  5916.         LibraryProcedure NetIdx, $(!DLLSQL), IntMultiply $(LoopIdx),3
  5917.         set-add NetIdx = $(NetIdx),2
  5918.         set NetTmpList = *( $(!NetworkSelList), $(NetIdx) )
  5919.         ifcontains(i) $(NetTmpList) in $(!ValidNetLibs)
  5920.             ifstr(i) $(NetTmpList) == $(!UserProvided)
  5921.                 set DefListItems = >( $(DefListItems), $(TheCheckIdx))
  5922.             else
  5923.                 ForListDo $(!NetLibList)
  5924.                     ifstr(i) $(NetTmpList) == $($)
  5925.                         set DefListItems = >( $(DefListItems), $(TheCheckIdx))
  5926.                     EndForListDo
  5927.                     goto endLoop
  5928.                 endif
  5929.             EndForListDo
  5930.         endif
  5931. endLoop =+
  5932.         set-add TheCheckIdx = $(TheCheckIdx),1
  5933.     endif
  5934. EndForListDo
  5935.     ifstr(i) $(!AllowExit) == "YES"
  5936.         read-syms NetworkDlgEx$(!STF_LANGUAGE)
  5937.     else
  5938.         read-syms NetworkDlg$(!STF_LANGUAGE)
  5939.     endif
  5940.     LibraryProcedure DlgNetwork, $(!DLLSQL), SQLDlgDisplay $(STF_HWND),$(DlgTemplate),"",$(!SQLDlgNames),"3",$(!NetworkSelList),$(DefListItems)
  5941. donet =+
  5942.     EndWait
  5943.     LibraryProcedure DLGEVENT, $(!DLLSQL), WaitEvent
  5944.     ifstr(i) $(DLGEVENT) == "CONTINUE"
  5945.         set Status = STATUS_OK
  5946.         LibraryProcedure !NetSelList, $(!DLLSQL), ExtractListSet $(DlgNetwork),"1"
  5947.         set !NetLibList = {}
  5948.         set !NetAddresses = {}
  5949.         set NetSelNum = "0"
  5950.         set NmPipesOn = "FALSE"
  5951.         ForListDo $(!NetSelList)
  5952.             set-sub LoopIdx = $(#),1
  5953.             LibraryProcedure NetIdx, $(!DLLSQL), IntMultiply $(LoopIdx),3
  5954.             set-add NetIdx = $(NetIdx),2
  5955.             set NetTmpList = *( $(!NetSelList), $(NetIdx) )
  5956.             ifcontains(i) $(NetTmpList) in $(!ValidNetLibs)
  5957.                 set-add NetSelNum = $(NetSelNum),1
  5958.                 ifstr(i) $(NetTmpList) == $(!UserProvided)
  5959.                     set-add NetIdx = $(NetIdx),1
  5960.                     set NetAddress = *( $(!NetSelList), $(NetIdx) )
  5961.                     set !NetAddresses = >( $(!NetAddresses), $(NetAddress))
  5962.                     set-sub NetIdx = $(NetIdx),2
  5963.                     set NetTmpList = *( $(!NetSelList), $(NetIdx) )
  5964.                     set !NetLibList = >( $(!NetLibList), $(NetTmpList))
  5965.                 else
  5966.                     ifstr(i) $(NetTmpList) == $(!NetLibPipes)
  5967.                         set NmPipesOn = "TRUE"
  5968.                     endif
  5969.                     ifstr(i) $(NetTmpList) == $(!NetLibTCPIP)
  5970.                         LibraryProcedure Result, $(!DLLSQL), GetServiceState "\\"$(!ComputerName),$(!TCPIPService)
  5971.                         ifstr(i) $(Result) != "SERVICE_RUNNING"
  5972.                             read-syms TCPIPNotRunning$(!STF_LANGUAGE)
  5973.                             read-syms InfoMessage$(!STF_LANGUAGE)
  5974.                             ui start $(DlgTemplate)
  5975.                             goto donet
  5976.                         endif
  5977.                     endif
  5978.                     set !NetLibList = >( $(!NetLibList), $(NetTmpList))
  5979.                 endif
  5980.             endif
  5981.         EndForListDo
  5982.         ifstr(i) $(!InstallType) == "1"
  5983.             ifstr(i) $(NmPipesOn) != "TRUE"
  5984.                 read-syms MustHavePipes$(!STF_LANGUAGE)
  5985.                 shell "" MessageError
  5986.                 goto donet
  5987.             endif
  5988.         endif
  5989.         ifstr(i) $(NetSelNum) == "0"
  5990.             read-syms NoNets$(!STF_LANGUAGE)
  5991.             shell "" MessageError
  5992.             goto donet
  5993.         endif
  5994.     else-ifstr(i) $(DLGEVENT) == "EXIT"
  5995.         ifstr(i) $(!AllowExit) == "YES"
  5996.             shell "" QueryUserQuit $(!STF_LANGUAGE)
  5997.             ifstr(i) $($R1) == "OK"
  5998.                 set Status = "STATUS_USERQUIT"
  5999.                 goto end_donet
  6000.             else
  6001.                 goto donet
  6002.             endif
  6003.         endif
  6004.     else-ifstr(i) $(DLGEVENT) == "BACK"
  6005.         set Status = "STATUS_BACK"
  6006.     endif
  6007. end_donet =+
  6008.     LibraryProcedure Result, $(!DLLSQL), CloseDialog $(DlgNetwork)
  6009. endDoNetwork =+
  6010.     Return $(Status)
  6011.     
  6012. [RegWriteClientKeys]
  6013.     set Status = "STATUS_FAILED"
  6014.     LibraryProcedure OpenSetupKey, $(!DLLSQL), RegMakeKey $($0),$(!RegSQLClientSetup),"",""
  6015.     ifstr(i) $(OpenSetupKey) == "KEY_ERROR"
  6016.         read-syms ErrorUpdatingRegistry$(!STF_LANGUAGE)
  6017.         LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)
  6018.         goto cli_regend
  6019.     endif
  6020.     LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenSetupKey),$(!RegValSQLPath),$(!RegTypeString),$(!SQLPath),""
  6021.     ifstr(i) $(Result) != "KEY_ERROR"
  6022.         set Status = "STATUS_SUCCESSFUL"
  6023.     endif
  6024. cli_regend =+
  6025.     LibraryProcedure Result, $(!DLLSQL), RegClose $(OpenSetupKey)
  6026.     Return $(Status)
  6027.     
  6028. [UpdateRegistry]
  6029.     StartWait
  6030.     set Status = "STATUS_FAILED"
  6031.     LibraryProcedure OpenVersionKey, $(!DLLSQL), RegMakeKey "\\"$(!ComputerName),$(!RegSQLServerServer),$(!RegSQLServerVer),$(!AdminACL)
  6032.     ifstr(i) $(OpenVersionKey) == "KEY_ERROR"
  6033.         read-syms ErrorUpdatingRegistry$(!STF_LANGUAGE)
  6034.         LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)
  6035.         goto upd_regend
  6036.     endif
  6037.     
  6038.     LibraryProcedure OpenServerKey, $(!DLLSQL), RegMakeKey "\\"$(!ComputerName),$(!RegSQLServer),$(!RegSQLServerSvr),$(!AdminACL)
  6039.     ifstr(i) $(OpenServerKey) == "KEY_ERROR"
  6040.         read-syms ErrorUpdatingRegistry$(!STF_LANGUAGE)
  6041.         LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)
  6042.         goto upd_regend
  6043.     endif
  6044.     
  6045.     LibraryProcedure OpenSetupKey, $(!DLLSQL), RegMakeKey "\\"$(!ComputerName),$(!RegSQLSetup),"",""
  6046.     ifstr(i) $(OpenSetupKey) == "KEY_ERROR"
  6047.         read-syms ErrorUpdatingRegistry$(!STF_LANGUAGE)
  6048.         LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)
  6049.         goto upd_regend
  6050.     endif
  6051.     
  6052.     LibraryProcedure OpenSchKey, $(!DLLSQL), RegMakeKey "\\"$(!ComputerName),$(!RegSQLServer),$(!SQLSchedulerService),""
  6053.     ifstr(i) $(OpenSchKey) == "KEY_ERROR"
  6054.         read-syms ErrorUpdatingRegistry$(!STF_LANGUAGE)
  6055.         LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)
  6056.         goto upd_regend
  6057.     endif
  6058.     
  6059.     LibraryProcedure OpenReplKey, $(!DLLSQL), RegMakeKey "\\"$(!ComputerName),$(!RegSQLServer),$(!RegValSQLReplication),""
  6060.     ifstr(i) $(OpenSchKey) == "KEY_ERROR"
  6061.         read-syms ErrorUpdatingRegistry$(!STF_LANGUAGE)
  6062.         LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)
  6063.         goto upd_regend
  6064.     endif
  6065.     
  6066.     LibraryProcedure OpenSchsubKey, $(!DLLSQL), RegMakeKey "\\"$(!ComputerName),$(!RegSQLServer),$(!SQLSchedulerService)"\"$(!SQLSchedulerSubService),""
  6067.     ifstr(i) $(OpenSchKey) == "KEY_ERROR"
  6068.         read-syms ErrorUpdatingRegistry$(!STF_LANGUAGE)
  6069.         LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)
  6070.         goto upd_regend
  6071.     endif
  6072.     
  6073.     LibraryProcedure OpenMgrKey, $(!DLLSQL), RegMakeKey "\\"$(!ComputerName),$(!RegSQLServer),$(!RegSQLSvcMgr),""
  6074.     ifstr(i) $(OpenMgrKey) == "KEY_ERROR"
  6075.         read-syms ErrorUpdatingRegistry$(!STF_LANGUAGE)
  6076.         LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)
  6077.         goto upd_regend
  6078.     endif
  6079.     
  6080.     LibraryProcedure OpenMManagementKey, $(!DLLSQL), RegMakeKey "\\"$(!ComputerName),$(!RegMManagement),"",""
  6081.     ifstr(i) $(OpenMManagementKey) == "KEY_ERROR"
  6082.         read-syms ErrorUpdatingRegistry$(!STF_LANGUAGE)
  6083.         LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)
  6084.         goto upd_regend
  6085.     endif
  6086.     
  6087.     LibraryProcedure OpenLMSvrKey, $(!DLLSQL), RegMakeKey "\\"$(!ComputerName),$(!RegLMSvrParams),$(!RegSQLSvrParam),$(!AdminACL)
  6088.     ifstr(i) $(OpenLMSvrKey) == "KEY_ERROR"
  6089.         read-syms ErrorUpdatingRegistry$(!STF_LANGUAGE)
  6090.         LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)
  6091.         goto upd_regend
  6092.     endif
  6093.     
  6094.     LibraryProcedure OpenPriorityKey, $(!DLLSQL), RegMakeKey "\\"$(!ComputerName),$(!RegPriorityCtrl),"",""
  6095.     ifstr(i) $(OpenPriorityKey) == "KEY_ERROR"
  6096.         read-syms ErrorUpdatingRegistry$(!STF_LANGUAGE)
  6097.         LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)
  6098.         goto upd_regend
  6099.     endif
  6100.     
  6101.     shell "" RegWriteELog "\\"$(!ComputerName)
  6102.     ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  6103.         goto upd_regend
  6104.     endif
  6105.     
  6106.     shell "" RegWriteSystemPaths "\\"$(!ComputerName),$(!RegSystemPaths),""
  6107.     ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  6108.         goto upd_regend
  6109.     endif
  6110.     
  6111.     shell "" RegWriteDBLibDefaults "\\"$(!ComputerName)
  6112.     
  6113.     shell "" RegWriteVersion $(OpenVersionKey)
  6114.     
  6115.     LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenServerKey),$(!RegValTapeWait),$(!RegTypeDWord),"-1","NOEXIST_WRITE"
  6116.     
  6117.     LibraryProcedure DefDomain, $(!DLLSQL), GetAccountName "DOMAIN"
  6118.     ifstr(i) $(DefDomain) == "WORKGROUP"
  6119.         set DefDomain = $(!ComputerName)
  6120.     else-ifstr(i) $(DefDomain) == "DOMAIN"
  6121.         set DefDomain = $(!ComputerName)
  6122.     endif
  6123.     shell "" RegWriteSecuritySupport "0",$(!DefGuest),$(DefDomain),"0",$(!DefSecMap1),$(!DefSecMap2),$(!DefSecMap3),"0","NOFORCE"
  6124.     
  6125.     ifstr(i) $(!InstallType) == "2"
  6126.         LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenServerKey),$(!RegValListenOn),$(!RegTypeMulti),$(!OldListenOn),""
  6127.     else
  6128.         shell "" RegWriteListenOn $(OpenServerKey),$($0),$($1)
  6129.     endif
  6130.     
  6131.     
  6132.     LibraryProcedure Temp, $(!DLLSQL), StrBeforeAndAfter $(!SQLPath),"AFTER",":"
  6133.     LibraryProcedure NewSQLPath, $(!DLLSQL), AppendToString $(!LogicalSQLDrive),$(Temp)
  6134.     LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenSetupKey),$(!RegValSQLPath),$(!RegTypeString),$(NewSQLPath),""
  6135.     LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenSetupKey),$(!RegValSetupState),$(!RegTypeString),$(!RegValInstalled),""
  6136.     LibraryProcedure InsCRC,$(!DLLSQL), GetInstallCRC
  6137.     LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenSetupKey),$(!RegValSetupCRC),$(!RegTypeString),$(InsCRC),""
  6138.     
  6139.     ifstr(i) $(!EvalVersion) == "YES"
  6140.         LibraryProcedure SQLEvalKey, $(!DLLSQL), RegMakeKey "\\"$(!ComputerName),$(!RegSQLEvaluation), $(!RegSQLEval),""
  6141.         ifstr(i) $(SQLEvalKey) == "KEY_ERROR"
  6142.             read-syms ErrorUpdatingRegistry$(!STF_LANGUAGE)
  6143.             LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)
  6144.             goto upd_regend
  6145.         endif
  6146.     endif
  6147.     
  6148.     shell "" RegWriteSchedulerSvc $(OpenSchKey)
  6149.     
  6150.     shell "" RegWriteSchedulerSubSvc $(OpenSchsubKey)
  6151.     
  6152.     shell "" RegWriteReplication $(OpenReplKey)
  6153.     
  6154.     shell "" RegUpdateRdrThreads
  6155.     
  6156.     shell "" RegWritePerfMon "\\"$(!ComputerName)
  6157.     
  6158.     shell "" RegWriteGroupOrder "\\"$(!ComputerName)
  6159.     
  6160.     LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenLMSvrKey),$(!RegValLMSvrAnno),$(!RegTypeDWord),"1",""
  6161.     LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenLMSvrKey),$(!RegLMSize),$(!RegTypeDWord),"3",""
  6162.     set LMNullSessionPipes = {}
  6163.     LibraryProcedure LMNullSessionPipes, $(!DLLSQL), RegRead $(OpenLMSvrKey),$(!RegValNullPipes)
  6164.     ifcontains(i) $(!RegValEpmapper) in $(LMNullSessionPipes)
  6165.         goto nomapper
  6166.     else
  6167.         set LMNullSessionPipes = >( $(LMNullSessionPipes),$(!RegValEpmapper) )
  6168.         LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenLMSvrKey),$(!RegValNullPipes),$(!RegTypeMulti),$(LMNullSessionPipes),""
  6169.     endif
  6170.     
  6171. nomapper =+
  6172.     LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenMManagementKey),$(!RegMMSystemCache),$(!RegTypeDWord),"0",""
  6173.     LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenPriorityKey),$(!RegSysPriority),$(!RegTypeDWord),"0",""
  6174.     
  6175.     LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenMgrKey),$(!RegValSvcMgrVerify),$(!RegTypeDWord),"0","NOEXIST_WRITE"
  6176.     LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenMgrKey),$(!RegValSvcMgrSvcs),$(!RegTypeMulti),$(!DefSvcMgrServices),""
  6177.     LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenMgrKey),$(!RegValSvcMgrDefSvc),$(!RegTypeString),$(!SQLServerService),"NOEXIST_WRITE"
  6178.     LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenMgrKey),$(!RegValSvcMgrRemote),$(!RegTypeDWord),"1","NOEXIST_WRITE"
  6179.     
  6180.     LibraryProcedure Result, $(!DLLSQL), GetServiceState "\\"$(!ComputerName), $(!SNMPService)
  6181.     ifstr(i) $(Result) != "SERVICE_NOT_EXIST"
  6182.         shell "" RegWriteSNMP
  6183.     endif
  6184.     
  6185.     set Status = "STATUS_SUCCESSFUL"
  6186.     
  6187. upd_regend =+
  6188.     LibraryProcedure Result, $(!DLLSQL), RegClose $(OpenVersionKey)
  6189.     LibraryProcedure Result, $(!DLLSQL), RegClose $(OpenServerKey)
  6190.     LibraryProcedure Result, $(!DLLSQL), RegClose $(OpenSetupKey)
  6191.     LibraryProcedure Result, $(!DLLSQL), RegClose $(OpenSchKey)
  6192.     LibraryProcedure Result, $(!DLLSQL), RegClose $(OpenSchsubKey)
  6193.     LibraryProcedure Result, $(!DLLSQL), RegClose $(OpenReplKey)
  6194.     LibraryProcedure Result, $(!DLLSQL), RegClose $(OpenMgrKey)
  6195.     LibraryProcedure Result, $(!DLLSQL), RegClose $(OpenMManagementKey)
  6196.     LibraryProcedure Result, $(!DLLSQL), RegClose $(OpenLMSvrKey)
  6197.     LibraryProcedure Result, $(!DLLSQL), RegClose $(OpenPriorityKey)
  6198.     EndWait
  6199.     Return $(Status)
  6200.     
  6201. [RegUpdateRdrThreads]
  6202.     LibraryProcedure LanKey, $(!DLLSQL), RegMakeKey "\\"$(!ComputerName),$(!RegSCM)"\"$(!LANManWksta),$(!RegSQLSvrParam),$(!AdminACL)
  6203.     ifstr(i) $(LanKey) != "KEY_ERROR"
  6204.         LibraryProcedure LanThreads, $(!DLLSQL), RegRead $(LanKey),$(!RegValMaxThreads)
  6205.         ifstr(i) $(LanThreads) == "KEY_ERROR"
  6206.             set LanThreads = $(!RegMaxThreadDefault)
  6207.         else
  6208.             ifint $(LanThreads) < $(!RegMaxThreadDefault)
  6209.                 set LanThreads = $(!RegMaxThreadDefault)
  6210.             else
  6211.                 set LanThreads = ""
  6212.             endif
  6213.         endif
  6214.         ifstr(i) $(LanThreads) != ""
  6215.             LibraryProcedure Result, $(!DLLSQL), RegSet $(LanKey),$(!RegValMaxThreads),$(!RegTypeDWord),$(LanThreads),""
  6216.         endif
  6217.         LibraryProcedure Result, $(!DLLSQL), RegClose $(LanKey)
  6218.     endif
  6219.     Return
  6220.     
  6221. [RegWriteSystemPaths]
  6222.     set Status = "STATUS_FAILED"
  6223.     ifstr(i) $(!STF_OS) == "NT"
  6224.         shell "" RegDeleteSystemPaths $($0),$($1),$($2)
  6225.         ifstr(i) $($R0) == "STATUS_SUCCESSFUL"
  6226.             LibraryProcedure OpenSysPathKey, $(!DLLSQL), RegMakeKey $($0),$($1),"","",$($2)
  6227.             ifstr(i) $(OpenSysPathKey) == "KEY_ERROR"
  6228.                 read-syms ErrorUpdatingRegistry$(!STF_LANGUAGE)
  6229.                 LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)
  6230.             else
  6231.                 LibraryProcedure SysPath, $(!DLLSQL), RegRead $(OpenSysPathKey),$(!RegValSysPath)
  6232.                 LibraryProcedure Temp, $(!DLLSQL), StrBeforeAndAfter $(!SQLPath),"AFTER",":"
  6233.                 LibraryProcedure NewSQLPath, $(!DLLSQL), AppendToString $(!LogicalSQLDrive),$(Temp)
  6234.                 ifstr(i) $(SysPath) != "KEY_ERROR"
  6235.                     ifstr(i) $(SysPath) == ""
  6236.                         ifstr(i) $(!NewInstall) != "TRUE"
  6237.                             ifstr(i) $(!InstallType) == "1"
  6238.                                 LibraryProcedure SysPath, $(!DLLSQL), InsertInString $(SysPath),$(!OldSQLPath)"\"$(!Binaries),$(NewSQLPath)"\"$(!Binaries),";"
  6239.                             else
  6240.                                 ifstr(i) $(!RegistryRebuild) != ""
  6241.                                     LibraryProcedure SysPath, $(!DLLSQL), InsertInString $(SysPath),$(!OldSQLPath)"\"$(!Binaries),$(NewSQLPath)"\"$(!Binaries),";"
  6242.                                 else
  6243.                                     LibraryProcedure SysPath, $(!DLLSQL), AppendToString $(SysPath),$(NewSQLPath)"\"$(!Binaries),";"
  6244.                                 endif
  6245.                             endif
  6246.                         else
  6247.                             LibraryProcedure SysPath, $(!DLLSQL), AppendToString $(SysPath),$(NewSQLPath)"\"$(!Binaries),";"
  6248.                         endif
  6249.                     else
  6250.                         ifstr(i) $(!NewInstall) != "TRUE"
  6251.                             ifstr(i) $(!InstallType) == "1"
  6252.                                 LibraryProcedure SysPath, $(!DLLSQL), InsertInString $(SysPath),$(!OldSQLPath)"\"$(!Binaries),$(NewSQLPath)"\"$(!Binaries),";"
  6253.                             else
  6254.                                 ifstr(i) $(!RegistryRebuild) != ""
  6255.                                     LibraryProcedure SysPath, $(!DLLSQL), InsertInString $(SysPath),$(!OldSQLPath)"\"$(!Binaries),$(NewSQLPath)"\"$(!Binaries),";"
  6256.                                 else
  6257.                                     LibraryProcedure SysPath, $(!DLLSQL), AppendToString $(SysPath),";"$(NewSQLPath)"\"$(!Binaries),";"
  6258.                                 endif
  6259.                             endif
  6260.                         else
  6261.                             LibraryProcedure SysPath, $(!DLLSQL), AppendToString $(SysPath),";"$(NewSQLPath)"\"$(!Binaries),";"
  6262.                         endif
  6263.                     endif
  6264.                 else
  6265.                     set SysPath = $(NewSQLPath)"\"$(!Binaries)
  6266.                 endif
  6267.                 LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenSysPathKey),$(!RegValSysPath),$(!RegTypeExpString),$(SysPath),""
  6268.                 LibraryProcedure Result, $(!DLLSQL), RegClose $(OpenSysPathKey)
  6269.                 set Status = "STATUS_SUCCESSFUL"
  6270.             endif
  6271.         endif
  6272.     else
  6273.         LibraryProcedure Result, $(!DLLSQL), SetNewPath $(!SQLPath)"\"$(!Binaries),"TRUE","FALSE"
  6274.         ifstr(i) $(Result) == "READONLY"
  6275.             read-syms ReadOnlyAutoexec$(!STF_LANGUAGE)
  6276.         endif
  6277.         set Status = "STATUS_SUCCESSFUL"
  6278.     endif
  6279.     Return $(Status)
  6280.     
  6281. [RegWriteTapeSupport]
  6282.     set Status = "STATUS_FAILED"
  6283.     LibraryProcedure OpenDOSDevKey, $(!DLLSQL), RegMakeKey $($0),$(!RegSystemPaths),$(!RegSysDOSDev),""
  6284.     ifstr(i) $(OpenDOSDevKey) == "KEY_ERROR"
  6285.         read-syms ErrorUpdatingRegistry$(!STF_LANGUAGE)
  6286.         LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)
  6287.     else
  6288.         LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenDOSDevKey),$(!RegValType0),$(!RegTypeString),$(!DefTapeDev),""
  6289.         LibraryProcedure Result, $(!DLLSQL), RegClose $(OpenDOSDevKey)
  6290.         set Status = "STATUS_SUCCESSFUL"
  6291.     endif
  6292.     Return $(Status)
  6293.         
  6294. [RegWriteSecuritySupport]
  6295.     set Status = "STATUS_FAILED"
  6296.     LibraryProcedure OpenSecKey, $(!DLLSQL), RegMakeKey "\\"$(!ComputerName),$(!RegSQLServer)"\"$(!RegSQLServerSvr),"",$(!AdminACL)
  6297.     ifstr(i) $(OpenDBLibKey) == "KEY_ERROR"
  6298.         read-syms ErrorUpdatingRegistry$(!STF_LANGUAGE)
  6299.         LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)
  6300.     else
  6301.         ifstr(i) $($8) == "FORCE"
  6302.             set UpdateMode = ""
  6303.         else
  6304.             set UpdateMode = "NOEXIST_WRITE"
  6305.         endif
  6306.         LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenSecKey),$(!RegSecLoginMode),$(!RegTypeDWord),$($0),$(UpdateMode)
  6307.         LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenSecKey),$(!RegSecDefAccount),$(!RegTypeString),$($1),$(UpdateMode)
  6308.         LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenSecKey),$(!RegSecDefDomain),$(!RegTypeString),$($2),$(UpdateMode)
  6309.         LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenSecKey),$(!RegSecAuditLevel),$(!RegTypeDWord),$($3),$(UpdateMode)
  6310.         LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenSecKey),$(!RegSecMap1),$(!RegTypeString),$($4),$(UpdateMode)
  6311.         LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenSecKey),$(!RegSecMap2),$(!RegTypeString),$($5),$(UpdateMode)
  6312.         LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenSecKey),$(!RegSecMap3),$(!RegTypeString),$($6),$(UpdateMode)
  6313.         LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenSecKey),$(!RegSecHostname),$(!RegTypeDWord),$($7),$(UpdateMode)
  6314.         LibraryProcedure Result, $(!DLLSQL), RegClose $(OpenSecKey)
  6315.         set Status = "STATUS_SUCCESSFUL"
  6316.     endif
  6317.     Return $(Status)
  6318.         
  6319. [RegGetSecuritySupport]
  6320.     set Status = "STATUS_FAILED"
  6321.     set LoginMode = "1"
  6322.     set DefAccount = $(!DefGuest)
  6323.     LibraryProcedure DefDomain, $(!DLLSQL), GetAccountName "DOMAIN"
  6324.     ifstr(i) $(DefDomain) == "WORKGROUP"
  6325.         set DefDomain = $(!ComputerName)
  6326.     else-ifstr(i) $(DefDomain) == "DOMAIN"
  6327.         set DefDomain = $(!ComputerName)
  6328.     endif
  6329.     set DefAuditLevel = "0"
  6330.     set DefMap1 = $(!DefSecMap1)
  6331.     set DefMap2 = $(!DefSecMap2)
  6332.     set DefMap3 = $(!DefSecMap3)
  6333.     set DefSetHostname = "0"
  6334.     LibraryProcedure OpenSecKey, $(!DLLSQL), RegOpen "\\"$(!ComputerName),$(!RegSQLServer)"\"$(!RegSQLServerSvr)
  6335.     ifstr(i) $(OpenSecKey) != "KEY_ERROR"
  6336.         LibraryProcedure LoginMode, $(!DLLSQL), RegRead $(OpenSecKey),$(!RegSecLoginMode)
  6337.         ifstr(i) $(LoginMode) == "KEY_ERROR"
  6338.             set LoginMode = "1"
  6339.         else
  6340.             ifstr(i) $(LoginMode) != ""
  6341.                 set-add LoginMode = $(LoginMode),1
  6342.             else
  6343.                 set LoginMode = "1"
  6344.             endif
  6345.         endif
  6346.         LibraryProcedure Result, $(!DLLSQL), RegRead $(OpenSecKey),$(!RegSecDefAccount)
  6347.         ifstr(i) $(Result) != "KEY_ERROR"
  6348.             ifstr(i) $(Result) != ""
  6349.                 set DefAccount = $(Result)
  6350.             endif
  6351.         endif
  6352.         LibraryProcedure Result, $(!DLLSQL), RegRead $(OpenSecKey),$(!RegSecDefDomain)
  6353.         ifstr(i) $(Result) != "KEY_ERROR"
  6354.             ifstr(i) $(Result) != ""
  6355.                 set DefDomain = $(Result)
  6356.             endif
  6357.         endif
  6358.         LibraryProcedure Result, $(!DLLSQL), RegRead $(OpenSecKey),$(!RegSecAuditLevel)
  6359.         ifstr(i) $(Result) != "KEY_ERROR"
  6360.             ifstr(i) $(Result) != ""
  6361.                 set DefAuditLevel = $(Result)
  6362.             endif
  6363.         endif
  6364.         LibraryProcedure Result, $(!DLLSQL), RegRead $(OpenSecKey),$(!RegSecHostname)
  6365.         ifstr(i) $(Result) != "KEY_ERROR"
  6366.             ifstr(i) $(Result) != ""
  6367.                 set DefSetHostname = $(Result)
  6368.             endif
  6369.         endif
  6370.         LibraryProcedure Result, $(!DLLSQL), RegRead $(OpenSecKey),$(!RegSecMap1)
  6371.         ifstr(i) $(Result) != "KEY_ERROR"
  6372.             set DefMap1 = $(Result)
  6373.         endif
  6374.         LibraryProcedure Result, $(!DLLSQL), RegRead $(OpenSecKey),$(!RegSecMap2)
  6375.         ifstr(i) $(Result) != "KEY_ERROR"
  6376.             set DefMap2 = $(Result)
  6377.         endif
  6378.         LibraryProcedure Result, $(!DLLSQL), RegRead $(OpenSecKey),$(!RegSecMap3)
  6379.         ifstr(i) $(Result) != "KEY_ERROR"
  6380.             set DefMap3 = $(Result)
  6381.         endif
  6382.         LibraryProcedure Result, $(!DLLSQL), RegClose $(OpenSecKey)
  6383.         set Status = "STATUS_SUCCESSFUL"
  6384.     endif
  6385.     Return $(Status),$(LoginMode),$(DefAccount),$(DefDomain),$(DefAuditLevel),$(DefMap1),$(DefMap2),$(DefMap3),$(DefSetHostname)
  6386.         
  6387. [RegWriteSerialNumberInfo]
  6388.     set Status = "STATUS_FAILED"
  6389.     LibraryProcedure OpenVersionKey, $(!DLLSQL), RegMakeKey "\\"$(!ComputerName),$(!RegSQLServerServer),$(!RegSQLServerVer),$(!AdminACL)
  6390.     ifstr(i) $(OpenVersionKey) != "KEY_ERROR"
  6391.         LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenVersionKey),$(!RegValRegOwner),$(!RegTypeString),$(!FullName),""
  6392.         LibraryProcedure SerialNo, $(!DLLSQL), CreateSerialNumber $(!SQLReleaseNumber),$(!FullName)
  6393.         LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenVersionKey),$(!RegValSerialNumber),$(!RegTypeDWord),$(SerialNo),""
  6394.         LibraryProcedure Result, $(!DLLSQL), RegClose $(OpenVersionKey)
  6395.         set Status = "STATUS_SUCCESSFUL"
  6396.     endif
  6397.     Return $(Status)
  6398.         
  6399. [RegUpdateTCPIPSupport]
  6400.     ifstr(i) $($0) == "TRUE"
  6401.         set Status = "STATUS_FAILED"
  6402.         LibraryProcedure OpenTCPIPKey, $(!DLLSQL), RegMakeKey "\\"$(!ComputerName),$(!RegTCPIPService),$(!RegSQLSvrParam),""
  6403.         ifstr(i) $(OpenTCPIPKey) != "KEY_ERROR"
  6404.             LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenTCPIPKey),$(!RegValTCPTries),$(!RegTypeDWord),"4",""
  6405.             LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenTCPIPKey),$(!RegValTCPCnt),$(!RegTypeDWord),"30",""
  6406.             LibraryProcedure Result, $(!DLLSQL), RegClose $(OpenTCPIPKey)
  6407.             set Status = "STATUS_SUCCESSFUL"
  6408.         endif
  6409.     else
  6410.         LibraryProcedure OpenTCPIPKey, $(!DLLSQL), RegOpen "\\"$(!ComputerName),$(!RegTCPIPService)"\"$(!RegSQLSvrParam)
  6411.         ifstr(i) $(OpenTCPIPKey) != "KEY_ERROR"
  6412.             LibraryProcedure Result, $(!DLLSQL), RegDelValue $(OpenTCPIPKey),$(!RegValTCPTries)
  6413.             LibraryProcedure Result, $(!DLLSQL), RegDelValue $(OpenTCPIPKey),$(!RegValTCPCnt)
  6414.             LibraryProcedure Result, $(!DLLSQL), RegClose $(OpenTCPIPKey)
  6415.         endif
  6416.         set Status = "STATUS_SUCCESSFUL"
  6417.     endif
  6418.     Return $(Status)
  6419.         
  6420. [RegWriteANSIOEM]
  6421.     set Status = "STATUS_FAILED"
  6422.     LibraryProcedure OpenDBLibKey, $(!DLLSQL), RegMakeKey $($0),$(!RegSQLClient),$(!RegSQLDBLib),""
  6423.     ifstr(i) $(OpenDBLibKey) == "KEY_ERROR"
  6424.         read-syms ErrorUpdatingRegistry$(!STF_LANGUAGE)
  6425.         LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)
  6426.     else
  6427.         LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenDBLibKey),$(!RegValANSIToOEM),$(!RegTypeString),$(!Chosen),""
  6428.         LibraryProcedure Result, $(!DLLSQL), RegClose $(OpenDBLibKey)
  6429.         set Status = "STATUS_SUCCESSFUL"
  6430.     endif
  6431.     Return $(Status)
  6432.         
  6433. [RegWriteDBLibDefaults]
  6434.     set Status = "STATUS_FAILED"
  6435.     LibraryProcedure OpenDBLibKey, $(!DLLSQL), RegMakeKey $($0),$(!RegSQLClient),$(!RegSQLDBLib),""
  6436.     ifstr(i) $(OpenDBLibKey) == "KEY_ERROR"
  6437.         read-syms ErrorUpdatingRegistry$(!STF_LANGUAGE)
  6438.         LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)
  6439.     else
  6440.         LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenDBLibKey),$(!RegValANSIToOEM),$(!RegTypeString),$(!ANSItoOEMDef),""
  6441.         LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenDBLibKey),$(!RegValUseIntl),$(!RegTypeString),$(!Chosen),""
  6442.         LibraryProcedure Result, $(!DLLSQL), RegClose $(OpenDBLibKey)
  6443.         set Status = "STATUS_SUCCESSFUL"
  6444.     endif
  6445.     Return $(Status)
  6446.     
  6447. [RegDeleteSystemPaths]
  6448.     set Status = "STATUS_FAILED"
  6449.     LibraryProcedure OpenSysPathKey, $(!DLLSQL), RegMakeKey $($0),$($1),"","",$($2)
  6450.     ifstr(i) $(OpenSysPathKey) == "KEY_ERROR"
  6451.         read-syms ErrorUpdatingRegistry$(!STF_LANGUAGE)
  6452.         LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)
  6453.     else
  6454.         LibraryProcedure Temp, $(!DLLSQL), StrBeforeAndAfter $(!SQLPath),"AFTER",":"
  6455.         ifstr(i) $(!RemoteComputer) == ""
  6456.             set !NewDefSQLPath = $(!SQLPath)
  6457.         else
  6458.             set !NewDefSQLPath = $(!LogicalSQLDrive)$(Temp)
  6459.         endif
  6460.         LibraryProcedure SysPath, $(!DLLSQL), RegRead $(OpenSysPathKey),$(!RegValSysPath)
  6461.         ifstr(i) $(SysPath) != "KEY_ERROR"
  6462.             LibraryProcedure Before, $(!DLLSQL), StrBeforeAndAfter $(SysPath),"BEFORESTRING",";"$(!NewDefSQLPath)"\"$(!Binaries)
  6463.             LibraryProcedure After, $(!DLLSQL), StrBeforeAndAfter $(SysPath),"AFTERSTRING",";"$(!NewDefSQLPath)"\"$(!Binaries)
  6464.             ifstr(i) $(Before) == ""
  6465.                 LibraryProcedure Before, $(!DLLSQL), StrBeforeAndAfter $(SysPath),"BEFORESTRING",$(!NewDefSQLPath)"\"$(!Binaries)
  6466.             endif
  6467.             ifstr(i) $(After) == ""
  6468.                 LibraryProcedure After, $(!DLLSQL), StrBeforeAndAfter $(SysPath),"AFTERSTRING",$(!NewDefSQLPath)"\"$(!Binaries)
  6469.             endif
  6470.             set NewSysPath = ""
  6471.             ifstr(i) $(Before) != ""
  6472.                 set NewSysPath = $(Before)
  6473.             endif
  6474.             ifstr(i) $(After) != ""
  6475.                 ifstr(i) $(NewSysPath) == ""
  6476.                     LibraryProcedure NewSysPath, $(!DLLSQL), AppendToString $(NewSysPath),$(After)
  6477.                 else
  6478.                     LibraryProcedure NewSysPath, $(!DLLSQL), AppendToString $(NewSysPath),";"$(After)
  6479.                 endif
  6480.             endif
  6481.             ifstr(i) $(NewSysPath) == ""
  6482.                 set NewSysPath = $(SysPath)
  6483.             endif
  6484.             set OldNewSysPath = $(NewSysPath)
  6485.             LibraryProcedure Before, $(!DLLSQL), StrBeforeAndAfter $(NewSysPath),"BEFORESTRING",";"$(!NewDefSQLPath)"\"$(!DLLs)
  6486.             LibraryProcedure After, $(!DLLSQL), StrBeforeAndAfter $(NewSysPath),"AFTERSTRING",";"$(!NewDefSQLPath)"\"$(!DLLs)
  6487.             ifstr(i) $(Before) == ""
  6488.                 LibraryProcedure Before, $(!DLLSQL), StrBeforeAndAfter $(NewSysPath),"BEFORESTRING",$(!NewDefSQLPath)"\"$(!DLLs)
  6489.             endif
  6490.             ifstr(i) $(After) == ""
  6491.                 LibraryProcedure After, $(!DLLSQL), StrBeforeAndAfter $(NewSysPath),"AFTERSTRING",$(!NewDefSQLPath)"\"$(!DLLs)
  6492.             endif
  6493.             set NewSysPath = ""
  6494.             ifstr(i) $(Before) != ""
  6495.                 set NewSysPath = $(Before)
  6496.             endif
  6497.             ifstr(i) $(After) != ""
  6498.                 ifstr(i) $(NewSysPath) == ""
  6499.                     LibraryProcedure NewSysPath, $(!DLLSQL), AppendToString $(NewSysPath),$(After)
  6500.                 else
  6501.                     LibraryProcedure NewSysPath, $(!DLLSQL), AppendToString $(NewSysPath),";"$(After)
  6502.                 endif
  6503.             endif
  6504.             ifstr(i) $(NewSysPath) == ""
  6505.                 set NewSysPath = $(OldNewSysPath)
  6506.             endif
  6507.             LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenSysPathKey),$(!RegValSysPath),$(!RegTypeExpString),$(NewSysPath),""
  6508.             LibraryProcedure Result, $(!DLLSQL), RegClose $(OpenSysPathKey)
  6509.         endif
  6510.         set Status = "STATUS_SUCCESSFUL"
  6511.     endif
  6512.     Return $(Status)
  6513.     
  6514. [RegWriteELog]
  6515.     set Status = "STATUS_FAILED"
  6516.     LibraryProcedure OpenELogKey, $(!DLLSQL), RegMakeKey $($0),$(!RegEventAppLog),$(!SQLSchedulerService),""
  6517.     ifstr(i) $(OpenELogKey) == "KEY_ERROR"
  6518.         read-syms ErrorUpdatingRegistry$(!STF_LANGUAGE)
  6519.         LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)
  6520.     else
  6521.         LibraryProcedure Temp, $(!DLLSQL), StrBeforeAndAfter $(!SQLPath),"AFTER",":"
  6522.         LibraryProcedure NewSQLPath, $(!DLLSQL), AppendToString $(!LogicalSQLDrive),$(Temp)
  6523.         LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenELogKey),$(!RegValELogMsgFile),$(!RegTypeString),$(NewSQLPath)"\"$(!Binaries)"\"$(!SQLSchEventDLL),""
  6524.         LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenELogKey),$(!RegValELogTypes),$(!RegTypeDWord),"7",""
  6525.         LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenELogKey),$(!RegValELogCMsgFile),$(!RegTypeString),$(NewSQLPath)"\"$(!Binaries)"\"$(!SQLSchEventDLL),""
  6526.         LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenELogKey),$(!RegValELogCCount),$(!RegTypeDWord),"4",""
  6527.         LibraryProcedure Result, $(!DLLSQL), RegClose $(OpenELogKey)
  6528.         set Status = "STATUS_SUCCESSFUL"
  6529.     endif
  6530.     LibraryProcedure OpenELogKey, $(!DLLSQL), RegMakeKey $($0),$(!RegEventAppLog),$(!SQLServerService),""
  6531.     ifstr(i) $(OpenELogKey) == "KEY_ERROR"
  6532.         read-syms ErrorUpdatingRegistry$(!STF_LANGUAGE)
  6533.         LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)
  6534.     else
  6535.         LibraryProcedure Temp, $(!DLLSQL), StrBeforeAndAfter $(!SQLPath),"AFTER",":"
  6536.         LibraryProcedure NewSQLPath, $(!DLLSQL), AppendToString $(!LogicalSQLDrive),$(Temp)
  6537.         LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenELogKey),$(!RegValELogMsgFile),$(!RegTypeString),$(NewSQLPath)"\"$(!Binaries)"\"$(!SQLEventDLL),""
  6538.         LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenELogKey),$(!RegValELogTypes),$(!RegTypeDWord),"255",""
  6539.         LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenELogKey),$(!RegValELogCMsgFile),$(!RegTypeString),$(NewSQLPath)"\"$(!Binaries)"\"$(!SQLEventDLL),""
  6540.         LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenELogKey),$(!RegValELogCCount),$(!RegTypeDWord),"8",""
  6541.         LibraryProcedure Result, $(!DLLSQL), RegClose $(OpenELogKey)
  6542.         set Status = "STATUS_SUCCESSFUL"
  6543.     endif
  6544.     LibraryProcedure OpenELogKey, $(!DLLSQL), RegMakeKey $($0),$(!RegEventAppLog),$(!SQLCtrs),""
  6545.     ifstr(i) $(OpenELogKey) == "KEY_ERROR"
  6546.         read-syms ErrorUpdatingRegistry$(!STF_LANGUAGE)
  6547.         LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)
  6548.     else
  6549.         LibraryProcedure Temp, $(!DLLSQL), StrBeforeAndAfter $(!SQLPath),"AFTER",":"
  6550.         LibraryProcedure NewSQLPath, $(!DLLSQL), AppendToString $(!LogicalSQLDrive),$(Temp)
  6551.         LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenELogKey),$(!RegValELogMsgFile),$(!RegTypeString),$(NewSQLPath)"\"$(!Binaries)"\"$(!EventCtrsDLL),""
  6552.         LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenELogKey),$(!RegValELogTypes),$(!RegTypeDWord),"7",""
  6553.         LibraryProcedure Result, $(!DLLSQL), RegClose $(OpenELogKey)
  6554.         set Status = "STATUS_SUCCESSFUL"
  6555.     endif
  6556.     Return $(Status)
  6557.     
  6558. [RegWriteVersion]
  6559.     set Status = "STATUS_SUCCESSFUL"
  6560.     LibraryProcedure Result, $(!DLLSQL), RegSet $($0),$(!RegValVersion),$(!RegTypeString),$(!ProductVersion),""
  6561.     LibraryProcedure Result, $(!DLLSQL), RegSet $($0),$(!RegValRegOrg),$(!RegTypeString),$(!OrgName),""
  6562.     LibraryProcedure Result, $(!DLLSQL), RegSet $($0),$(!RegValRegPID),$(!RegTypeString),$(!ProductID),""
  6563.     LibraryProcedure Result, $(!DLLSQL), RegSet $($0),$(!RegValSoftType),$(!RegTypeString),$(!RegSQLSysType),""
  6564.     Return $(Status)
  6565.     
  6566. [RegWriteSchedulerSvc]
  6567.     set Status = "STATUS_SUCCESSFUL"
  6568.     LibraryProcedure Result, $(!DLLSQL), RegSet $($0),$(!RegServerAutoStart),$(!RegTypeDWord),$(!RegValServerAutoStart),"NOEXIST_WRITE"
  6569.     LibraryProcedure Result, $(!DLLSQL), RegSet $($0),$(!RegSchRestart),$(!RegTypeDWord),$(!RegValSchedrestart),"NOEXIST_WRITE"
  6570.     LibraryProcedure Result, $(!DLLSQL), RegSet $($0),$(!RegSchSysLimit),$(!RegTypeDWord),$(!RegValLimitRows),"NOEXIST_WRITE"
  6571.     LibraryProcedure Result, $(!DLLSQL), RegSet $($0),$(!RegSchSysMax),$(!RegTypeDWord),$(!RegValMaxRows),"NOEXIST_WRITE"
  6572.     LibraryProcedure Result, $(!DLLSQL), RegSet $($0),$(!RegSchAutoMail),$(!RegTypeDWord),$(!RegValServerAutoStart),"NOEXIST_WRITE"
  6573.     LibraryProcedure Result, $(!DLLSQL), RegSet $($0),$(!RegSchServerHost),$(!RegTypeString),"","NOEXIST_WRITE"
  6574.     Return $(Status)
  6575.     
  6576. [RegWriteSchedulerSubSvc]
  6577.     set Status = "STATUS_SUCCESSFUL"
  6578.     LibraryProcedure Temp, $(!DLLSQL), StrBeforeAndAfter $(!SQLPath),"AFTER",":"
  6579.     LibraryProcedure NewSQLPath, $(!DLLSQL), AppendToString $(!LogicalSQLDrive),$(Temp)
  6580.     LibraryProcedure Result, $(!DLLSQL), RegSet $($0),$(!RegSchCmdExec),$(!RegTypeString),$(NewSQLPath)"\"$(!Binaries)"\"$(!SQLCmdExecDLL)","$(!RegValCmdExec),""
  6581.     LibraryProcedure Result, $(!DLLSQL), RegSet $($0),$(!RegSchReplSync),$(!RegTypeString),$(NewSQLPath)"\"$(!Binaries)"\"$(!SQLReplDLL)","$(!RegValReplSync),""
  6582.     LibraryProcedure Result, $(!DLLSQL), RegSet $($0),$(!RegSchReplReader),$(!RegTypeString),$(NewSQLPath)"\"$(!Binaries)"\"$(!SQLReplDLL)","$(!RegValReplReader),""
  6583.     LibraryProcedure Result, $(!DLLSQL), RegSet $($0),$(!RegSchReplDist),$(!RegTypeString),$(NewSQLPath)"\"$(!Binaries)"\"$(!SQLReplDLL)","$(!RegValReplDist),""
  6584.     Return $(Status)
  6585.     
  6586. [RegWriteReplication]
  6587.     set Status = "STATUS_SUCCESSFUL"
  6588.     LibraryProcedure Temp, $(!DLLSQL), StrBeforeAndAfter $(!SQLPath),"AFTER",":"
  6589.     LibraryProcedure NewSQLPath, $(!DLLSQL), AppendToString $(!LogicalSQLDrive),$(Temp)
  6590.     LibraryProcedure Result, $(!DLLSQL), RegSet $($0),$(!RegValReplDir),$(!RegTypeString),$(NewSQLPath)"\"$(!ReplDir),"NOEXIST_WRITE"
  6591.     LibraryProcedure Result, $(!DLLSQL), RegSet $($0),$(!RegValSQLReplDB),$(!RegTypeString),$(!RegSchReplLCDist),"NOEXIST_WRITE"
  6592.     Return $(Status)
  6593.         
  6594. [RegWriteListenOn]
  6595.     set Status = "STATUS_SUCCESSFUL"
  6596.     set RPCEncrypt = "FALSE"
  6597.     set NewNetLibList = {}
  6598.     set CurrentUserAddrIdx = 1
  6599.     ForListDo $($1)
  6600.         ifstr(i) $($) == $(!NetLibVines)
  6601.             set NewNetLibList = >( $(NewNetLibList), $($)","$(!StreetName))
  6602.         else-ifstr(i) $($) == $(!NetLibSPX)
  6603.             ifstr(i) $(!SocketNumber) == ""
  6604.                 set NewNetLibList = >( $(NewNetLibList), $($)","$(!ServiceName))
  6605.             else
  6606.                 set NewNetLibList = >( $(NewNetLibList), $($)","$(!ServiceName)","$(!SocketNumber))
  6607.             endif
  6608.         else-ifstr(i) $($) == $(!NetLibTCPIP)
  6609.             set NewNetLibList = >( $(NewNetLibList), $($)","$(!TCPIPSocketNumber))
  6610.         else-ifstr(i) $($) == $(!NetLibADSP)
  6611.             set NewNetLibList = >( $(NewNetLibList), $($)","$(!ADSPServiceName))
  6612.         else-ifstr(i) $($) == $(!NetLibDECNet)
  6613.             set NewNetLibList = >( $(NewNetLibList), $($)","$(!DECNetObjectID))
  6614.         else-ifstr(i) $($) == $(!NetLibPipes)
  6615.             set NewNetLibList = >( $(NewNetLibList), $($)","$(!ServerNMPipeName))
  6616.         else-ifstr(i) $($) == $(!NetLibRPC)
  6617.             set NewNetLibList = >( $(NewNetLibList), $($))
  6618.             set RPCEncrypt = "TRUE"
  6619.         else
  6620.             set NewNetLibList = >( $(NewNetLibList), $($)","*($($2),$(CurrentUserAddrIdx)))
  6621.             set-add CurrentUserAddrIdx = $(CurrentUserAddrIdx),1
  6622.         endif
  6623.         
  6624.         ifcontains(i) $(!NetLibTCPIP) in $($1)
  6625.             shell "" RegUpdateTCPIPSupport "TRUE"
  6626.         else
  6627.             shell "" RegUpdateTCPIPSupport "FALSE"
  6628.         endif
  6629.         
  6630.     EndForListDo
  6631.     
  6632.     LibraryProcedure Result, $(!DLLSQL), RegSet $($0),$(!RegValListenOn),$(!RegTypeMulti),$(NewNetLibList),""
  6633.     ifstr(i) $(RPCEncrypt) == "TRUE"
  6634.         LibraryProcedure OpenMPKey, $(!DLLSQL), RegMakeKey "\\"$(!ComputerName),$(!RegSQLServerServer),$(!RegRPCNetLib),$(!AdminACL)
  6635.         ifstr(i) $(OpenMPKey) == "KEY_ERROR"
  6636.             read-syms ErrorReadRegistry$(!STF_LANGUAGE)
  6637.             LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)
  6638.             goto endlistenon
  6639.         endif
  6640.         LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenMPKey),$(!RegValRPCSec),$(!RegTypeString),$(!MultiProtEncrypt),$(AdminACL)
  6641.         LibraryProcedure Result, $(!DLLSQL), RegClose $(OpenMPKey)
  6642.     endif
  6643.     
  6644. endlistenon =+
  6645.     Return $(Status)
  6646.         
  6647. [RegWriteGroupOrder]
  6648.     set Status = "STATUS_SUCCESSFUL"
  6649.     shell "" DoGroupOrderNuke $($0)
  6650.     set AppendedHandle = "0"
  6651.     LibraryProcedure GrpOrderKey, $(!DLLSQL), RegMakeKey $($0),$(!RegSystemGrpOrder),"",""
  6652.     ifstr(i) $(GrpOrderKey) != "KEY_ERROR"
  6653.         LibraryProcedure CntrsMem, $(!DLLSQL), RegRead $(GrpOrderKey),$(!RegValGrpOrderList),"ALLOC_HANDLE"
  6654.         ifstr(i) $(CntrsMem) != "KEY_ERROR"
  6655.             set OneEntry = {}
  6656.             set OneEntry = >( $(OneEntry), $(!SQLServerService))
  6657.             LibraryProcedure AppendedHandle, $(!DLLSQL), AppendToHandle $(CntrsMem),$(!RegTypeMulti),$(OneEntry)
  6658.             LibraryProcedure Result, $(!DLLSQL), RegSet $(GrpOrderKey),$(!RegValGrpOrderList),$(!RegTypeMulti),$(AppendedHandle),"","HANDLE"
  6659.         endif
  6660.         LibraryProcedure Result, $(!DLLSQL), RegClose $(GrpOrderKey)
  6661.     endif
  6662.     Return $(Status)
  6663.     
  6664. [RegWriteMailEnabled]
  6665.     set Status = "STATUS_SUCCESSFUL"
  6666.     set AppendedHandle = "0"
  6667.     LibraryProcedure OpenCntrKey, $(!DLLSQL), RegMakeKey $($0),$(!RegSQLServerServer),"",$(!AdminACL)
  6668.     ifstr(i) $(OpenCntrKey) != "KEY_ERROR"
  6669.         LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenCntrKey),$(!RegValMailEnabled),$(!RegTypeMulti),"","NOEXIST_WRITE"
  6670.         LibraryProcedure CntrsMem, $(!DLLSQL), RegRead $(OpenCntrKey),$(!RegValMailEnabled),"ALLOC_HANDLE"
  6671.         ifstr(i) $(CntrsMem) != "KEY_ERROR"
  6672.             set OneEntry = {}
  6673.             set OneEntry = >( $(OneEntry), $($1))
  6674.             LibraryProcedure AppendedHandle, $(!DLLSQL), AppendToHandle $(CntrsMem),$(!RegTypeMulti),$(OneEntry)
  6675.             LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenCntrKey),$(!RegValMailEnabled),$(!RegTypeMulti),$(AppendedHandle),"","HANDLE"
  6676.         endif
  6677.         LibraryProcedure Result, $(!DLLSQL), RegClose $(OpenCntrKey)
  6678.     endif
  6679.     Return $(Status)
  6680.     
  6681. [RegCopyMailInfo]
  6682.     set Status = "STATUS_SUCCESSFUL"
  6683.     LibraryProcedure OpenCUMailKey, $(!DLLSQL), RegMakeKey $($0),$(!RegSWMS),"Mail","" ,"TRUE"
  6684.     ifstr(i) $(OpenCUMailKey) != "KEY_ERROR"
  6685.         LibraryProcedure Result, $(!DLLSQL), Delnode "FILE_DELETE", $(!SQLPath)"\TMPMAIL0"
  6686.         LibraryProcedure Result, $(!DLLSQL), RegSave, $(OpenCUMailKey), $(!SQLPath)"\TMPMAIL0"
  6687.         LibraryProcedure Result, $(!DLLSQL), RegClose $(OpenCUMailKey)
  6688.         LibraryProcedure OpenDefMailKey, $(!DLLSQL), RegMakeKey $($0),".DEFAULT",$(!RegSWMS)"\Mail","","", "TRUE"
  6689.         ifstr(i) $(OpenDefMailKey) != "KEY_ERROR"
  6690.             LibraryProcedure Result, $(!DLLSQL), RegRestore, $(OpenDefMailKey), $(!SQLPath)"\TMPMAIL0"
  6691.             LibraryProcedure Result, $(!DLLSQL), Delnode "FILE_DELETE", $(!SQLPath)"\TMPMAIL0"
  6692.             LibraryProcedure Result, $(!DLLSQL), RegClose $(OpenDefMailKey)
  6693.         endif
  6694.     endif
  6695.     Return $(Status)
  6696.     
  6697. [RegWriteSNMP]
  6698.     set Status = "STATUS_FAIL"
  6699.     
  6700.     LibraryProcedure OpenSQLSNMPKey, $(!DLLSQL), RegMakeKey "\\"$(!ComputerName),$(!RegSQLServer), $(!RegSQLSNMP),""
  6701.     ifstr(i) $(OpenSQLSNMPKey) == "KEY_ERROR"
  6702.         read-syms ErrorUpdatingRegistry$(!STF_LANGUAGE)
  6703.         LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)
  6704.         goto end_regwsnmp
  6705.     endif
  6706.     
  6707.     LibraryProcedure OpenSQLSNMPVerKey, $(!DLLSQL), RegMakeKey "\\"$(!ComputerName), $(!RegSQLServer), $(!RegSQLSNMP)"\"$(!RegCurrentVer),""
  6708.     ifstr(i) $(OpenSQLSNMPVerKey) == "KEY_ERROR"
  6709.         read-syms ErrorUpdatingRegistry$(!STF_LANGUAGE)
  6710.         LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)
  6711.         goto end_regwsnmp
  6712.     endif
  6713.     
  6714.     LibraryProcedure OpenSNMPAgentsKey, $(!DLLSQL), RegMakeKey "\\"$(!ComputerName), $(!RegSCM)"\"$(!RegSNMPAgents), "", ""
  6715.     ifstr(i) $(OpenSQLSNMPVerKey) == "KEY_ERROR"
  6716.         read-syms ErrorUpdatingRegistry$(!STF_LANGUAGE)
  6717.         LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)
  6718.         goto end_regwsnmp
  6719.     endif
  6720.     
  6721.     LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenSQLSNMPVerKey), $(!RegValPathName), $(!RegTypeExpString), $(!SQLPath)"\"$(!Binaries)"\"$(!SQLSNMPDLL), ""
  6722.     
  6723.     set TmpList = {}
  6724.     set Idx = "0"
  6725.     LibraryProcedure TmpList, $(!DLLSQL), RegEnumKeyValues "\\"$(!ComputerName),$(!RegSCM)"\"$(!RegSNMPAgents),"VALUEDATA"
  6726.     ForListDo $(TmpList)
  6727.         LibraryProcedure TmpAfter, $(!DLLSQL), StrBeforeAndAfter $($), "AFTERSTRING", $(!RegSQLServerSvr)
  6728.         ifstr(i) $(TmpAfter) != ""
  6729.             set Idx = $(#)
  6730.         endif
  6731.     EndForListDo
  6732.     set TmpList = {}
  6733.     LibraryProcedure TmpList, $(!DLLSQL), RegEnumKeyValues "\\"$(!ComputerName),$(!RegSCM)"\"$(!RegSNMPAgents),"VALUENAMES"
  6734.     ifstr(i) $(Idx) == "0"
  6735.         set Max = "0"
  6736.         ForListDo $(TmpList)
  6737.             ifint $(Max) < $($)
  6738.                 set Max = $($)
  6739.             endif
  6740.         EndForListDo
  6741.         set-add ValueName = $(Max), 1
  6742.     else
  6743.         set ValueName = *($(TmpList), $(Idx))
  6744.     endif
  6745.     
  6746.     LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenSNMPAgentsKey), $(ValueName), $(!RegTypeString), $(!RegSQLServer)"\"$(!RegSQLSNMP)"\"$(!RegCurrentVer), ""
  6747.     
  6748.     set Status = "STATUS_SUCCESSFUL"
  6749.     
  6750. end_regwsnmp =+
  6751.     LibraryProcedure Result, $(!DLLSQL), RegClose $(OpenSQLSNMPVerKey)
  6752.     LibraryProcedure Result, $(!DLLSQL), RegClose $(OpenSQLSNMPKey)
  6753.     LibraryProcedure Result, $(!DLLSQL), RegClose $(OpenSNMPAgentsKey)
  6754.     
  6755.     Return $(Status)
  6756.     
  6757. [DoNukeSQLSNMPAgent]
  6758.         set Status = "STATUS_FAIL"
  6759.  
  6760.         LibraryProcedure OpenSNMPAgentsKey, $(!DLLSQL), RegOpen "\\"$(!ComputerName), $(!RegSCM)"\"$(!RegSNMPAgents)
  6761.         ifstr(i) $(OpenSQLSNMPVerKey) == "KEY_ERROR"
  6762.           read-syms ErrorUpdatingRegistry$(!STF_LANGUAGE)
  6763.           LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)
  6764.           goto end_regwsnmp
  6765.         endif
  6766.  
  6767.         set TmpList = {}
  6768.         set Idx = "0"
  6769.         LibraryProcedure TmpList, $(!DLLSQL), RegEnumKeyValues "\\"$(!ComputerName),$(!RegSCM)"\"$(!RegSNMPAgents),"VALUEDATA"
  6770.         ForListDo $(TmpList)
  6771.             LibraryProcedure TmpAfter, $(!DLLSQL), StrBeforeAndAfter $($), "AFTERSTRING", $(!RegSQLServerSvr)
  6772.             ifstr(i) $(TmpAfter) != ""
  6773.                 set Idx = $(#)
  6774.             endif
  6775.         EndForListDo
  6776.  
  6777.         ifstr(i) $(Idx) != "0"
  6778.             set TmpList = {}
  6779.             LibraryProcedure TmpList, $(!DLLSQL), RegEnumKeyValues "\\"$(!ComputerName),$(!RegSCM)"\"$(!RegSNMPAgents),"VALUENAMES"
  6780.             set ValueName = *($(TmpList), $(Idx))
  6781.             LibraryProcedure Result, $(!DLLSQL), RegDelValue $(OpenSNMPAgentsKey), $(ValueName)
  6782.         endif
  6783.  
  6784.         set Status = "STATUS_SUCCESSFUL"
  6785.  
  6786. end_nukesqlsnmp =+
  6787.         LibraryProcedure Result, $(!DLLSQL), RegClose $(OpenSNMPAgentsKey)
  6788.  
  6789.         return $(Status)
  6790.  
  6791. [DoGroupOrderNuke]
  6792.     set Status = "STATUS_SUCCESSFUL"
  6793.     set AppendedHandle = "0"
  6794.     LibraryProcedure GrpOrderKey, $(!DLLSQL), RegMakeKey $($0),$(!RegSystemGrpOrder),"",""
  6795.     ifstr(i) $(GrpOrderKey) != "KEY_ERROR"
  6796.         LibraryProcedure CntrsMem, $(!DLLSQL), RegRead $(GrpOrderKey),$(!RegValGrpOrderList),"ALLOC_HANDLE"
  6797.         ifstr(i) $(CntrsMem) != "KEY_ERROR"
  6798.             LibraryProcedure PriorHandle, $(!DLLSQL), BeforeAndAfterIdxSearchAlloc "BEFORESTRING",$(CntrsMem),$(!SQLServerService),"0"
  6799.             ifstr(i) $(PriorHandle) != "0"
  6800.                 LibraryProcedure AfterHandle, $(!DLLSQL), BeforeAndAfterIdxSearchAlloc "AFTERSTRING",$(CntrsMem),$(!SQLServerService),"0"
  6801.                 LibraryProcedure AppendedHandle, $(!DLLSQL), BeforeAndAfterIdxSearchAlloc "APPEND_HANDLES",$(PriorHandle),$(AfterHandle),""
  6802.             endif
  6803.             ifstr(i) $(AppendedHandle) != "0"
  6804.                 LibraryProcedure Result, $(!DLLSQL), RegSet $(GrpOrderKey),$(!RegValGrpOrderList),$(!RegTypeMulti),$(AppendedHandle),"","HANDLE"
  6805.             endif
  6806.         endif
  6807.         LibraryProcedure Result, $(!DLLSQL), RegClose $(GrpOrderKey)
  6808.     endif
  6809.     Return $(Status)
  6810.     
  6811. [DoMailNuke]
  6812.     set Status = "STATUS_SUCCESSFUL"
  6813.     LibraryProcedure OpenCntrKey, $(!DLLSQL), RegMakeKey $($0),$(!RegSQLServerServer),"",$(AdminACL)
  6814.     ifstr(i) $(OpenCntrKey) != "KEY_ERROR"
  6815.         LibraryProcedure CntrsMem, $(!DLLSQL), RegRead $(OpenCntrKey),$(!RegValMailEnabled),"ALLOC_HANDLE"
  6816.         ifstr(i) $(CntrsMem) != "KEY_ERROR"
  6817.             LibraryProcedure PriorHandle, $(!DLLSQL), BeforeAndAfterIdxSearchAlloc "BEFORESTRING",$(CntrsMem),$($1),"0"
  6818.             ifstr(i) $(PriorHandle) != "0"
  6819.                 LibraryProcedure AfterHandle, $(!DLLSQL), BeforeAndAfterIdxSearchAlloc "AFTERSTRING",$(CntrsMem),$($1),"0"
  6820.                 LibraryProcedure AppendedHandle, $(!DLLSQL), BeforeAndAfterIdxSearchAlloc "APPEND_HANDLES",$(PriorHandle),$(AfterHandle),""
  6821.                 ifstr(i) $(AppendedHandle) != "0"
  6822.                     LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenCntrKey),$(!RegValMailEnabled),$(!RegTypeMulti),$(AppendedHandle),"","HANDLE"
  6823.                 endif
  6824.             endif
  6825.         endif
  6826.         LibraryProcedure Result, $(!DLLSQL), RegClose $(OpenCntrKey)
  6827.     endif
  6828.     Return $(Status)
  6829.     
  6830. [DoPerfmonNuke]
  6831.     set Status = "STATUS_SUCCESSFUL"
  6832.     LibraryProcedure CurrentLocale, $(!DLLSQL), GetDefaultLocale
  6833.     LibraryProcedure SQLPerfKey, $(!DLLSQL), RegOpen $($0),$(!RegSCM)"\"$(!SQLServerService)"\"$(!RegSQLPerformance)
  6834.     ifstr(i) $(SQLPerfKey) != "KEY_ERROR"
  6835.         LibraryProcedure Temp, $(!DLLSQL), RegRead $(SQLPerfKey),$(!RegValFirstCntr)
  6836.         set FirstCntr = *($(Temp),1)
  6837.         LibraryProcedure LastCntr, $(!DLLSQL), RegRead $(SQLPerfKey),$(!RegValLastCntr)
  6838.         LibraryProcedure Temp, $(!DLLSQL), RegRead $(SQLPerfKey),$(!RegValFirstHelp)
  6839.         set FirstHelp = *($(Temp),1)
  6840.         LibraryProcedure LastHelp, $(!DLLSQL), RegRead $(SQLPerfKey),$(!RegValLastHelp)
  6841. nukeAnotherLocale =+
  6842.         LibraryProcedure OpenCntrKey, $(!DLLSQL), RegMakeKey $($0),$(!RegNTPerfLib),$(CurrentLocale),""
  6843.         ifstr(i) $(OpenCntrKey) != "KEY_ERROR"
  6844.             LibraryProcedure CntrsMem, $(!DLLSQL), RegRead $(OpenCntrKey),$(!RegValCounters),"ALLOC_HANDLE"
  6845.             ifstr(i) $(CntrsMem) != "KEY_ERROR"
  6846.                 LibraryProcedure PriorHandle, $(!DLLSQL), BeforeAndAfterIdxSearchAlloc "BEFORESTRING",$(CntrsMem),$(FirstCntr),"0"
  6847.                 ifstr(i) $(PriorHandle) != "0"
  6848.                     LibraryProcedure AfterHandle, $(!DLLSQL), BeforeAndAfterIdxSearchAlloc "AFTERSTRING",$(CntrsMem),$(LastCntr),"1"
  6849.                     LibraryProcedure AppendedHandle, $(!DLLSQL), BeforeAndAfterIdxSearchAlloc "APPEND_HANDLES",$(PriorHandle),$(AfterHandle),""
  6850.                     ifstr(i) $(AppendedHandle) != "0"
  6851.                         LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenCntrKey),$(!RegValCounters),$(!RegTypeMulti),$(AppendedHandle),"","HANDLE"
  6852.                     endif
  6853.                 endif
  6854.             endif
  6855.             
  6856.             LibraryProcedure HelpMem, $(!DLLSQL),  RegRead $(OpenCntrKey),$(!RegValHelp),"ALLOC_HANDLE"
  6857.             ifstr(i) $(HelpMem) != "KEY_ERROR"
  6858.                 LibraryProcedure PriorHandle, $(!DLLSQL), BeforeAndAfterIdxSearchAlloc "BEFORESTRING",$(HelpMem),$(FirstHelp),"0"
  6859.                 ifstr(i) $(PriorHandle) != "0"
  6860.                     LibraryProcedure AfterHandle, $(!DLLSQL), BeforeAndAfterIdxSearchAlloc "AFTERSTRING",$(HelpMem),$(LastHelp),"1"
  6861.                     LibraryProcedure AppendedHandle, $(!DLLSQL), BeforeAndAfterIdxSearchAlloc "APPEND_HANDLES",$(PriorHandle),$(AfterHandle),""
  6862.                     ifstr(i) $(AppendedHandle) != "0"
  6863.                         LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenCntrKey),$(!RegValHelp),$(!RegTypeMulti),$(AppendedHandle),"","HANDLE"
  6864.                     endif
  6865.                 endif
  6866.             endif
  6867.             LibraryProcedure OpenNTPerfKey, $(!DLLSQL), RegMakeKey $($0),$(!RegNTPerfLib),"",""
  6868.             ifstr(i) $(OpenNTPerfKey) != "KEY_ERROR"
  6869.                 LibraryProcedure LastNTCntr, $(!DLLSQL), RegRead $(OpenNTPerfKey),$(!RegValLastCntr)
  6870.                 LibraryProcedure LastNTHelp, $(!DLLSQL), RegRead $(OpenNTPerfKey),$(!RegValLastHelp)
  6871.                 ifstr(i) $(LastNTCntr) == $(LastCntr)
  6872.                     set-sub LastNTCntr = $(FirstCntr),2
  6873.                     set-sub LastNTHelp = $(FirstHelp),2
  6874.                     LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenNTPerfKey),$(!RegValLastCntr),$(!RegTypeDWord),$(LastNTCntr),""
  6875.                     LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenNTPerfKey),$(!RegValLastHelp),$(!RegTypeDWord),$(LastNTHelp),""
  6876.                 endif
  6877.                 LibraryProcedure Result, $(!DLLSQL), RegClose $(OpenNTPerfKey)
  6878.             endif
  6879.             
  6880.             ifstr(i) $(CurrentLocale) != $(!DefPerfLangID)
  6881.                 set CurrentLocale = $(!DefPerfLangID)
  6882.                 goto nukeAnotherLocale
  6883.             endif
  6884.         endif
  6885.         LibraryProcedure Result, $(!DLLSQL), RegClose $(SQLPerfKey)
  6886.     endif
  6887.     LibraryProcedure Result, $(!DLLSQL), RegEnumDelete "\\"$(!ComputerName),"UNIDELETE",$(!RegSCM),$(!SQLServerService)"\"$(!RegSQLPerformance)
  6888.     Return $(Status)
  6889.         
  6890. [RegWritePerfMon]
  6891.     set Status = "STATUS_SUCCESSFUL"
  6892.     LibraryProcedure CurrentLocale, $(!DLLSQL), GetDefaultLocale
  6893.     shell "" DoPerfmonNuke $($0)
  6894.     LibraryProcedure OpenNTPerfKey, $(!DLLSQL), RegMakeKey $($0),$(!RegSCM),$(!SQLServerService)"\"$(!RegSQLPerformance),""
  6895.     ifstr(i) $(OpenNTPerfKey) != "KEY_ERROR"
  6896.         LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenNTPerfKey),$(!RegValLibrary),$(!RegTypeString),$(!SQLCtrsDLL),""
  6897.         LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenNTPerfKey),$(!RegValOpen),$(!RegTypeString),"OpenSQLPerformanceData",""
  6898.         LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenNTPerfKey),$(!RegValCollect),$(!RegTypeString),"CollectSQLPerformanceData",""
  6899.         LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenNTPerfKey),$(!RegValClose),$(!RegTypeString),"CloseSQLPerformanceData",""
  6900.         LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenNTPerfKey),$(!RegValLoginTO),$(!RegTypeDWord),$(!LoginSleepPeriod),""
  6901.         LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenNTPerfKey),$(!RegValQueryTO),$(!RegTypeDWord),"30",""
  6902. anotherLocale =+
  6903.         LibraryProcedure OpenPerfKey, $(!DLLSQL), RegMakeKey $($0),$(!RegNTPerfLib),"",""
  6904.         ifstr(i) $(OpenPerfKey) != "KEY_ERROR"
  6905.             LibraryProcedure OpenCntrKey, $(!DLLSQL), RegMakeKey $($0),$(!RegNTPerfLib),$(CurrentLocale),""
  6906.             ifstr(i) $(OpenCntrKey) != "KEY_ERROR"
  6907.                 LibraryProcedure CntrsMem, $(!DLLSQL), RegRead $(OpenCntrKey),$(!RegValCounters),"ALLOC_HANDLE"
  6908.                 ifstr(i) $(CntrsMem) == "KEY_ERROR"
  6909.                     set CntrsMem = ""
  6910.                 endif
  6911.                 LibraryProcedure HelpMem, $(!DLLSQL),  RegRead $(OpenCntrKey),$(!RegValHelp),"ALLOC_HANDLE"
  6912.                 ifstr(i) $(HelpMem) == "KEY_ERROR"
  6913.                     set HelpMem = ""
  6914.                 endif
  6915.                 LibraryProcedure LastCounter, $(!DLLSQL), RegRead $(OpenPerfKey),$(!RegValLastCntr)
  6916.                 LibraryProcedure LastHelp, $(!DLLSQL), RegRead $(OpenPerfKey),$(!RegValLastHelp)
  6917.                 set CurrentCntr = $(LastCounter)
  6918.                 set OrigCntr = $(LastCounter)
  6919.                 set CurrentHelp = $(LastHelp)
  6920.                 set OrigHelp = $(LastHelp)
  6921.                 install LoadPerfLibrary
  6922.                 LibraryProcedure NumPerfCntrs, $(!PERFHANDLE), GetNumPerfCounters
  6923.                 
  6924.                 set PerfNameSQLSvrObj = {}
  6925.                 set PerfHelpSQLSvrObj = {}
  6926.                 set PerfSQLObjects = {}
  6927.                 set ListCntr = "1"
  6928.                 set-sub CntrLimit = $(NumPerfCntrs),1
  6929. listLoop =+
  6930.                 LibraryProcedure CntrListPair, $(!PERFHANDLE), GetPerfCounter $(ListCntr)
  6931.                 set PerfNameSQLSvrObj = >( $(PerfNameSQLSvrObj), *($(CntrListPair), 1))
  6932.                 set PerfHelpSQLSvrObj = >( $(PerfHelpSQLSvrObj), *($(CntrListPair), 2))
  6933.                 
  6934.                 ifstr(i) *($(CntrListPair), 1) == *($(CntrListPair), 2)
  6935.                     set PerfSQLObjects = >( $(PerfSQLObjects), $(ListCntr))
  6936.                 endif
  6937.                 ifint $(ListCntr) > $(CntrLimit)
  6938.                 else
  6939.                     set-add ListCntr = $(ListCntr),1
  6940.                     goto listLoop
  6941.                 endif
  6942.                 
  6943.                 install FreePerfLibrary
  6944.                 
  6945.                 set-add CurrentCntr = $(CurrentCntr),"2"
  6946.                 set-add CurrentHelp = $(CurrentHelp),"2"
  6947.                 shell "" DoCreateObjectCntrList $(PerfSQLObjects),$(CurrentCntr)
  6948.                 LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenNTPerfKey),$(!RegValFirstCntr),$(!RegTypeMulti),$($R0),""
  6949.                 shell "" DoCreateObjectCntrList $(PerfSQLObjects),$(CurrentHelp)
  6950.                 LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenNTPerfKey),$(!RegValFirstHelp),$(!RegTypeMulti),$($R0),""
  6951.                 
  6952.                 ForListDo $(PerfNameSQLSvrObj)
  6953.                     set OneEntry = {}
  6954.                     set OneEntry = >( $(OneEntry), $(CurrentCntr))
  6955.                     set OneEntry = >( $(OneEntry), $($))
  6956.                     LibraryProcedure CntrsMem, $(!DLLSQL), AppendToHandle $(CntrsMem),$(!RegTypeMulti),$(OneEntry)
  6957.                     set-add CurrentCntr = $(CurrentCntr),"2"
  6958.                 EndForListDo
  6959.                 set-sub CurrentCntr = $(CurrentCntr),2
  6960.                 LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenCntrKey),$(!RegValCounters),$(!RegTypeMulti),$(CntrsMem),"","HANDLE"
  6961.                 LibraryProcedure Result, $(!DLLSQL), FreeHandle $(CntrsMem)
  6962.                 
  6963.                 ForListDo $(PerfHelpSQLSvrObj)
  6964.                     set OneEntry = {}
  6965.                     set OneEntry = >( $(OneEntry), $(CurrentHelp))
  6966.                     set OneEntry = >( $(OneEntry), $($))
  6967.                     LibraryProcedure HelpMem, $(!DLLSQL), AppendToHandle $(HelpMem),$(!RegTypeMulti),$(OneEntry)
  6968.                     set-add CurrentHelp = $(CurrentHelp),"2"
  6969.                 EndForListDo
  6970.                 set-sub CurrentHelp = $(CurrentHelp),2
  6971.                 LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenCntrKey),$(!RegValHelp),$(!RegTypeMulti),$(HelpMem),"","HANDLE"
  6972.                 LibraryProcedure Result, $(!DLLSQL), FreeHandle $(HelpMem)
  6973.                 
  6974.                 ifstr(i) $(CurrentLocale) == $(!DefPerfLangID)
  6975.                     LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenPerfKey),$(!RegValLastCntr),$(!RegTypeDWord),$(CurrentCntr),""
  6976.                     LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenPerfKey),$(!RegValLastHelp),$(!RegTypeDWord),$(CurrentHelp),""
  6977.                     LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenNTPerfKey),$(!RegValLastCntr),$(!RegTypeDWord),$(CurrentCntr),""
  6978.                     LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenNTPerfKey),$(!RegValLastHelp),$(!RegTypeDWord),$(CurrentHelp),""
  6979.                 else
  6980.                     LibraryProcedure Result, $(!DLLSQL), RegClose $(OpenPerfKey)
  6981.                     LibraryProcedure Result, $(!DLLSQL), RegClose $(OpenCntrKey)
  6982.                     set CurrentLocale = $(!DefPerfLangID)
  6983.                     goto anotherLocale
  6984.                 endif
  6985.                 LibraryProcedure Result, $(!DLLSQL), RegClose $(OpenPerfKey)
  6986.             endif
  6987.             LibraryProcedure Result, $(!DLLSQL), RegClose $(OpenCntrKey)
  6988.         endif
  6989.         LibraryProcedure Result, $(!DLLSQL), RegClose $(OpenNTPerfKey)
  6990.     endif
  6991.     Return $(Status)
  6992.         
  6993. [DoCreateObjectCntrList]
  6994.     set Objects = {}
  6995.     ForListDo $($0)
  6996.         set-sub Cntr = $($),1
  6997.         LibraryProcedure Idx, $(!DLLSQL), IntMultiply $(Cntr),2
  6998.         set-add Idx = $(Idx), $($1)
  6999.         set Objects = >( $(Objects), $(Idx))
  7000.     EndForListDo
  7001.     return $(Objects)
  7002.     
  7003. [UpdateOleReg]
  7004.     
  7005.     set !DlgHandle = ""
  7006.     set Status = "STATUS_SUCCESSFUL"
  7007.     ifstr(i) $($0) == ""
  7008.         ifstr(i) $(!RegistryRebuild) == ""
  7009.             ifstr(i) $(!InstallType) == "1"
  7010.                 LibraryProcedure !DlgHandle, $(!DLLSQL), BillBoard $(STF_HWND),"",$(!SQLDlgNames)
  7011.                 read-syms BillboardOle$(!STF_LANGUAGE)
  7012.                 LibraryProcedure Result, $(!DLLSQL), UpdateBillboard $(!DlgHandle),$(!BillName)
  7013.             else
  7014.                 read-syms BillboardOle$(!STF_LANGUAGE)
  7015.                 LibraryProcedure Result, $(!DLLSQL), UpdateBillboard $($1),$(!BillName)
  7016.             endif
  7017.         endif
  7018.     endif
  7019.     StartWait
  7020.     ifstr(i) $(!RemoteComputer) == ""
  7021.         LibraryProcedure Results, $(!DLLSQL), DoOleRegistration $(!SQLPath)"\"$(!Binaries)"\"$(!SQLOle32),"REGISTER"
  7022.         ifstr(i) $(Results) != "TRUE"
  7023.             set !MsgText = $(Results)
  7024.             set Status = "STATUS_FAILED"
  7025.             goto end_UpdateOle
  7026.         endif
  7027.         LibraryProcedure Results, $(!DLLSQL), DoOleRegistration $(!SQLPath)"\"$(!Binaries)"\"$(!ODSOle32),"REGISTER"
  7028.         ifstr(i) $(Results) != "TRUE"
  7029.             set !MsgText = $(Results)
  7030.             set Status = "STATUS_FAILED"
  7031.             goto end_UpdateOle
  7032.         endif
  7033.         ProcessExecute Result,"WAIT",$(!STF_WINDOWSPATH)"\"$(!RegEdit)" /s "$(!SQLPath)"\"$(!Binaries)"\"$(!MSDTCOle)
  7034.     else
  7035.         shell "" StartService $(!SQLServerService)
  7036.         set CmdLine = $(!RemoteSystemRoot)"\"$(!RegEdit)" /s "$(!RemSQLPath)"\"$(!Binaries)"\"$(!MSDTCOle)"' ""  /o"$(!SQLPath)"\"$(!InstallDir)"\MSDTCOLE.OUT /P"$(!SAPassword)
  7037.         ProcessExecute Result,"WAIT",$(!SQLPath)"\"$(!Binaries)"\"$(!ISQL)" /n /S"$(!ServerName)" /Usa /Q"" exec xp_cmdshell '"$(CmdLine)
  7038.         shell "" StopService $(!SQLServerService)
  7039.     endif
  7040.     EndWait
  7041.     ifstr(i) $(Result) == "PROCESS_ERROR"
  7042.         read-syms ProcessExecError$(!STF_LANGUAGE)
  7043.         LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!RegEdit)" "$(!AddlText)
  7044.         set Status = "STATUS_FAILED"
  7045.         goto end_UpdateOle
  7046.     else-ifstr(i) $(Result) != "0"
  7047.         read-syms ProcessRetError$(!STF_LANGUAGE)
  7048.         LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!RegEdit)" "$(!AddlText)" "$(Result)
  7049.         set Status = "STATUS_FAILED"
  7050.     endif
  7051. end_UpdateOle=+
  7052.     ifstr(i) $(!DlgHandle) != ""
  7053.         LibraryProcedure Result, $(!DLLSQL), CloseDialog $(!DlgHandle)
  7054.     endif
  7055.     return $(Status)
  7056.     
  7057. [InstallODBC]
  7058.     set !DlgHandle = ""
  7059.     set !ODBCError = ""
  7060.     set !NonCriticalODBCInstallFail = ""
  7061.     set Status = "STATUS_SUCCESSFUL"
  7062.     ifstr(i) $(!RegistryRebuild) == ""
  7063.         ifstr(i) $(!RemoteComputer) == ""
  7064.             LibraryProcedure !DlgHandle, $(!DLLSQL), BillBoard $(STF_HWND),"",$(!SQLDlgNames)
  7065.             read-syms BillboardODBC$(!STF_LANGUAGE)
  7066.             LibraryProcedure Result, $(!DLLSQL), UpdateBillboard $(!DlgHandle),$(!BillName)
  7067.             LibraryProcedure !ODBCError, $(!DLLSQL), SetupODBC $(!ODBCDir),$(!ODBCDrv)
  7068.             ifstr(i) $(!ODBCError) != ""
  7069.                 set Status = "STATUS_FAILED"
  7070.                 set !NonCriticalODBCInstallFail = "1"
  7071.             endif
  7072.             ifstr(i) $(!DlgHandle) != ""
  7073.                 LibraryProcedure Result, $(!DLLSQL), CloseDialog $(!DlgHandle)
  7074.                 set !DlgHandle = ""
  7075.             endif
  7076.         else
  7077.             LibraryProcedure !DlgHandle, $(!DLLSQL), BillBoard $(STF_HWND),"",$(!SQLDlgNames)
  7078.             read-syms BillboardODBC$(!STF_LANGUAGE)
  7079.             LibraryProcedure Result, $(!DLLSQL), UpdateBillboard $(!DlgHandle),$(!BillName)
  7080.             StartWait
  7081.             shell "" StartService $(!SQLServerService)
  7082.             ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  7083.                 EndWait
  7084.                 goto finish_odbc
  7085.             endif
  7086.             ProcessExecute Result,"WAIT",$(!SQLPath)"\"$(!Binaries)"\"$(!ISQL)" /n /S"$(!ServerName)" /Usa /Q"" exec sp_addextendedproc 'xp_odbcinst','instodbc'"" /o"$(!SQLPath)"\"$(!InstallDir)"\ODBC1.OUT /P"$(!SAPassword)
  7087.             EndWait
  7088.             ifstr(i) $(Result) == "PROCESS_ERROR"
  7089.                 read-syms ProcessExecError$(!STF_LANGUAGE)
  7090.                 LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!ISQL)" "$(!AddlText)
  7091.                 goto finish_odbc
  7092.             else-ifstr(i) $(Result) != "0"
  7093.                 read-syms ProcessRetError$(!STF_LANGUAGE)
  7094.                 LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!ISQL)" "$(!AddlText)" "$(Result)
  7095.                 goto finish_odbc
  7096.             endif
  7097.             StartWait
  7098.             ProcessExecute Result,"WAIT",$(!SQLPath)"\"$(!Binaries)"\"$(!ISQL)" /n /S"$(!ServerName)" /Usa /Q"" exec xp_odbcinst '"$(!RemSQLPath)"\"$(!SQLODBCDir)"', 'SQL Server'""  /o"$(!SQLPath)"\"$(!InstallDir)"\ODBC2.OUT /P"$(!SAPassword)
  7099.             EndWait
  7100.             ifstr(i) $(Result) == "PROCESS_ERROR"
  7101.                 read-syms ProcessExecError$(!STF_LANGUAGE)
  7102.                 LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!ISQL)" "$(!AddlText)
  7103.                 goto finish_odbc
  7104.             else-ifstr(i) $(Result) != "0"
  7105.                 read-syms ProcessRetError$(!STF_LANGUAGE)
  7106.                 LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!ISQL)" "$(!AddlText)" "$(Result)
  7107.                 goto finish_odbc
  7108.             endif
  7109.             StartWait
  7110.             ProcessExecute Result,"WAIT",$(!SQLPath)"\"$(!Binaries)"\"$(!ISQL)" /n /S"$(!ServerName)" /Usa /Q"" exec sp_dropextendedproc 'xp_odbcinst'""  /o"$(!SQLPath)"\"$(!InstallDir)"\ODBC3.OUT /P"$(!SAPassword)
  7111.             EndWait
  7112.             ifstr(i) $(Result) == "PROCESS_ERROR"
  7113.                 read-syms ProcessExecError$(!STF_LANGUAGE)
  7114.                 LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!ISQL)" "$(!AddlText)
  7115.                 goto finish_odbc
  7116.             else-ifstr(i) $(Result) != "0"
  7117.                 read-syms ProcessRetError$(!STF_LANGUAGE)
  7118.                 LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!ISQL)" "$(!AddlText)" "$(Result)
  7119.                 goto finish_odbc
  7120.             endif
  7121.             StartWait
  7122.             ProcessExecute Result,"WAIT",$(!SQLPath)"\"$(!Binaries)"\"$(!ISQL)" /n /S"$(!ServerName)" /Usa /Q"" DBCC instodbc(FREE)""  /o"$(!SQLPath)"\"$(!InstallDir)"\ODBC4.OUT /P"$(!SAPassword)
  7123.             EndWait
  7124.             ifstr(i) $(Result) == "PROCESS_ERROR"
  7125.                 read-syms ProcessExecError$(!STF_LANGUAGE)
  7126.                 LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!ISQL)" "$(!AddlText)
  7127.                 goto finish_odbc
  7128.             else-ifstr(i) $(Result) != "0"
  7129.                 read-syms ProcessRetError$(!STF_LANGUAGE)
  7130.                 LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!ISQL)" "$(!AddlText)" "$(Result)
  7131.                 goto finish_odbc
  7132.             endif
  7133.         endif
  7134.     endif
  7135. finish_odbc=+
  7136.     ifstr(i) $(!RemoteComputer) != ""
  7137.         shell "" StopService $(!SQLServerService)
  7138.     endif
  7139.     ifstr(i) $(!DlgHandle) != ""
  7140.         LibraryProcedure Result, $(!DLLSQL), CloseDialog $(!DlgHandle)
  7141.     endif
  7142.     return $(Status)
  7143.     
  7144. [RegisterMSDTC]
  7145.     Set Status = "STATUS_SUCCESSFUL"
  7146.     set Cmd = "MSDTC -install "$(!MSDTCService)" "$(!SQLPath)"\"$(!Binaries)" "$(!SQLPath)"\"$(!DataDir)
  7147.     ifstr(i) $(!RemoteComputer) == ""
  7148.         ProcessExecute Result,"WAIT",$(Cmd)
  7149.         ifstr(i) $(Result) == "PROCESS_ERROR"
  7150.             set Status = "STATUS_FAILED"
  7151.         endif
  7152.     else
  7153.         StartWait
  7154.         shell "" StartService $(!SQLServerService)
  7155.         ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  7156.             EndWait
  7157.             goto finish_instmsdtc
  7158.         endif
  7159.         StartWait
  7160.         ProcessExecute Result,"WAIT",$(!SQLPath)"\"$(!Binaries)"\"$(!ISQL)" /n /S"$(!ServerName)" /Usa /Q"" exec xp_cmdshell '$(Cmd)'""  /o"$(!SQLPath)"\"$(!InstallDir)"\MSDTC.OUT /P"$(!SAPassword)
  7161.         EndWait
  7162.         ifstr(i) $(Result) == "PROCESS_ERROR"
  7163.             read-syms ProcessExecError$(!STF_LANGUAGE)
  7164.             LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!ISQL)" "$(!AddlText)
  7165.             set Status = "STATUS_FAILED"
  7166.         else-ifstr(i) $(Result) != "0"
  7167.             read-syms ProcessRetError$(!STF_LANGUAGE)
  7168.             LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!ISQL)" "$(!AddlText)" "$(Result)
  7169.             set Status = "STATUS_FAILED"
  7170.         endif
  7171.     endif
  7172. finish_instmsdtc =+
  7173.     ifstr(i) $(!RemoteComputer) != ""
  7174.         shell "" StopService $(!SQLServerService)
  7175.     endif
  7176.     return $(Status)
  7177.     
  7178. [UpdateSCM]
  7179.     set Status = "STATUS_FAILED"
  7180.     set ErrorNumber = ""
  7181.     set OpenSQLKey = ""
  7182.     read-syms BillboardSCM$(!STF_LANGUAGE)
  7183.     LibraryProcedure Result, $(!DLLSQL), UpdateBillboard $(!DlgHandle),$(!BillName)
  7184.     
  7185.     LibraryProcedure OpenSQLKey, $(!DLLSQL), RegMakeKey "\\"$(!ComputerName),$(!RegSQLServer),"",""
  7186.     LibraryProcedure OpenParamKey, $(!DLLSQL), RegMakeKey "\\"$(!ComputerName),$(!RegSQLServerServer),$(!RegSQLSvrParam),$(!AdminACL)
  7187.     ifstr(i) $(OpenParamKey) == "KEY_ERROR"
  7188.         set ErrorNumber = " #SCM1"
  7189.         goto end_updateSCM
  7190.     endif
  7191.     
  7192.     ifstr(i) $(!RemoteComputer) == ""
  7193.         set NewSQLPath = $(!SQLPath)
  7194.         set NewMasterPath = $(!MasterDBPath)
  7195.     else
  7196.         LibraryProcedure Temp, $(!DLLSQL), StrBeforeAndAfter $(!SQLPath),"AFTER",":"
  7197.         LibraryProcedure NewSQLPath, $(!DLLSQL), AppendToString $(!LogicalSQLDrive),$(Temp)
  7198.         LibraryProcedure Temp, $(!DLLSQL), StrBeforeAndAfter $(!MasterDBPath),"AFTER",":"
  7199.         LibraryProcedure NewMasterPath, $(!DLLSQL), AppendToString $(!LogicalDBDrive),$(Temp)
  7200.     endif
  7201.     ifstr(i) $($0) == "TRUE"
  7202.         LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenParamKey),$(!RegValParameter)"0",$(!RegTypeString),"-d"$(NewMasterPath)"\"$(!MasterDBFileName),""
  7203.         LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenParamKey),$(!RegValParameter)"1",$(!RegTypeString),"-e"$(NewSQLPath)"\"$(!LogDir)"\"$(!ErrorLog),""
  7204.         ifstr(i) $(!InstallType) != "1"
  7205.             ifstr(i) $(!SQL95Keys) != "TRUE"
  7206.                 LibraryProcedure Result, $(!DLLSQL), DoServiceOp "\\"$(!ComputerName),"SERVICE_REMOVE",$(!SQLMonitorService),"",""
  7207.                 LibraryProcedure Result, $(!DLLSQL), DoServiceOp "\\"$(!ComputerName),"SERVICE_REMOVE",$(!SQLOldServerService),"",""
  7208.             endif
  7209.         endif
  7210.         LibraryProcedure Result, $(!DLLSQL), DoServiceOp "\\"$(!ComputerName),"SERVICE_REMOVE",$(!SQLSchedulerService),"",""
  7211.         LibraryProcedure Result, $(!DLLSQL), DoServiceOp "\\"$(!ComputerName),"SERVICE_REMOVE",$(!SQLServerService),"",""
  7212.         LibraryProcedure Result, $(!DLLSQL), DoServiceOp "\\"$(!ComputerName),"SERVICE_REMOVE",$(!MSDTCService),"",""
  7213.         set pollLoop = "1"
  7214.         ifstr(i) $(!AutoServerService) == "CHECKED"
  7215.             set StartType = "A"
  7216.         else
  7217.             set StartType = ""
  7218.         endif
  7219. pollSvrCreate =+
  7220.             LibraryProcedure Result, $(!DLLSQL), DoServiceOp "\\"$(!ComputerName),"SERVICE_CREATE",$(!SQLServerService),$(NewSQLPath)"\"$(!Binaries)"\"$(!SQLServer),"","","",$(StartType),"1"
  7221.         ifstr(i) $(Result) != ""
  7222.             ifint $(pollLoop) < "5"
  7223.                 set-add pollLoop = $(pollLoop),1
  7224.                 goto pollSvrCreate
  7225.             endif
  7226.             LibraryProcedure Err, $(!DLLSQL), GetLastSetupError
  7227.             set ErrorNumber = " #SCM2 - "$(Err)
  7228.             goto end_updateSCM
  7229.         endif
  7230.         set pollLoop = "1"
  7231.         ifstr(i) $(!AutoSchedulerService) == "CHECKED"
  7232.             set StartType = "A"
  7233.         else
  7234.             set StartType = ""
  7235.         endif
  7236. add_scheduler_svc =+
  7237.         LibraryProcedure Result, $(!DLLSQL), DoServiceOp "\\"$(!ComputerName),"SERVICE_CREATE",$(!SQLSchedulerService),$(NewSQLPath)"\"$(!Binaries)"\"$(!SQLSchedulerEXE),$(!UserName),$(!UserPassword),"",$(StartType)
  7238.         ifstr(i) $(Result) != ""
  7239.             ifint $(pollLoop) < "5"
  7240.                 set-add pollLoop = $(pollLoop),1
  7241.                 goto add_scheduler_svc
  7242.             endif
  7243.             LibraryProcedure Err, $(!DLLSQL), GetLastSetupError
  7244.             set ErrorNumber = " #SCM3 - "$(Err)
  7245.             goto end_updateSCM
  7246.         endif
  7247.         
  7248.         shell "" DoExtractMasterAndErrorlog "\\"$(!ComputerName)
  7249.         set MasterEntry = $($R0)
  7250.         set ELogEntry = $($R1)
  7251.         LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenParamKey),$(MasterEntry),$(!RegTypeString),"-d"$(NewMasterPath)"\"$(!MasterDBFileName),""
  7252.         LibraryProcedure Result, $(!DLLSQL), RegSet $(OpenParamKey),$(ELogEntry),$(!RegTypeString),"-e"$(NewSQLPath)"\"$(!LogDir)"\"$(!ErrorLog),""
  7253.     endif
  7254.     set Status = "STATUS_SUCCESSFUL"
  7255.     LibraryProcedure Result, $(!DLLSQL), RegClose $(OpenParamKey)
  7256. end_updateSCM =+
  7257.     ifstr(i) $(OpenSQLKey) != ""
  7258.         LibraryProcedure Result, $(!DLLSQL), RegClose $(OpenSQLKey)
  7259.     endif
  7260.     Return $(Status) $(ErrorNumber)
  7261.         
  7262. [StartService]
  7263.     set Status = "STATUS_FAILED"
  7264.     set Svc = $($0)
  7265.     ifstr(i) $(Svc) == $(!SQLServerService)
  7266.         set Delay = "15"
  7267.     else
  7268.         set Delay = "10"
  7269.     endif
  7270.     StartWait
  7271. restart_service =+
  7272.     LibraryProcedure Result, $(!DLLSQL), DoServiceOp "\\"$(!ComputerName),"SERVICE_START",$(Svc),"",""
  7273.     ifstr(i) $(Result) != ""
  7274.         goto endStartServ
  7275.     endif
  7276.     LibraryProcedure Result, $(!DLLSQL), Sleepy $(Delay)
  7277.     set PollTime = "0"
  7278. pollstate =+
  7279.     LibraryProcedure Result, $(!DLLSQL), GetServiceState "\\"$(!ComputerName),$(Svc)
  7280.     ifstr(i) $(Result) == "SERVICE_LIMBO"
  7281.         ifint $(PollTime) > "120"
  7282.             goto endStartServ
  7283.         endif
  7284.         LibraryProcedure Result, $(!DLLSQL), Sleepy "5"
  7285.         set-add PollTime = $(PollTime),5
  7286.         goto pollstate
  7287.     endif
  7288.     ifstr(i) $(Result) == "SERVICE_RUNNING"
  7289.         set Status = "STATUS_SUCCESSFUL"
  7290.     endif
  7291. endStartServ =+
  7292.     ifstr(i) $($1) == "TestCreate"
  7293.         ifstr(i) $(Result) == "SVC_NO_PATH"
  7294.             set Status = "STATUS_SUCCESSFUL"
  7295.             goto donestart
  7296.         endif
  7297.     endif
  7298.     ifstr(i) $(Result) == "CANNOT_LOGON_SERVICE"
  7299.         set Status = "STATUS_FAILED"
  7300.         goto donestart
  7301.     endif
  7302.     ifstr(i) $(Status) != "STATUS_SUCCESSFUL"
  7303.         read-syms NetStartError$(!STF_LANGUAGE)
  7304.         LibraryProcedure Err, $(!DLLSQL), GetLastSetupError
  7305.         LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(Svc)" - "$(!AddlText)" - "$(Err)
  7306.     endif
  7307. donestart=+
  7308.     EndWait
  7309.     Return $(Status) $(Result)
  7310.     
  7311. [StopService]
  7312.     set Status = "STATUS_FAILED"
  7313.     set Svc = $($0)
  7314.     set Delay = "5"
  7315.     StartWait
  7316.     LibraryProcedure Result, $(!DLLSQL), DoServiceOp "\\"$(!ComputerName),"SERVICE_STOP",$(Svc),"",""
  7317.     ifstr(i) $(Result) == "SERVICE_NOT_EXIST"
  7318.         set Status = "STATUS_SUCCESSFUL"
  7319.         goto endStopSQL
  7320.     else-ifstr(i) $(Result) != ""
  7321.         goto endStopSQL
  7322.     endif
  7323.     set PollTime = "0"
  7324. pollstate =+
  7325.     LibraryProcedure Result, $(!DLLSQL), GetServiceState "\\"$(!ComputerName),$(Svc)
  7326.     ifstr(i) $(Result) == "SERVICE_LIMBO"
  7327.         ifint $(PollTime) > "120"
  7328.             goto endStopSQL
  7329.         endif
  7330.         LibraryProcedure Result, $(!DLLSQL), Sleepy $(Delay)
  7331.         set-add PollTime = $(PollTime), $(Delay)
  7332.         goto pollstate
  7333.     endif
  7334.     ifstr(i) $(Result) == "SERVICE_STOPPED"
  7335.         set Status = "STATUS_SUCCESSFUL"
  7336.     endif
  7337. endStopSQL =+
  7338.     ifstr(i) $(Status) != "STATUS_SUCCESSFUL"
  7339.         read-syms NetStopError$(!STF_LANGUAGE)
  7340.         LibraryProcedure Err, $(!DLLSQL), GetLastSetupError
  7341.         LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(Svc)" -  "$(!AddlText)" - "$(Err)
  7342.     endif
  7343.     ifstr(i) $(!RemoteComputer) == ""
  7344.         ifstr(i) $(Svc) == $(!SQLServerService)
  7345.             LibraryProcedure SemPresent, $(!DLLSQL), IsSQLSemaphoreActive ""
  7346.             ifstr(i) $(SemPresent) == "SEMAPHORE_PRESENT"
  7347.                 LibraryProcedure Result, $(!DLLSQL), SQLLogin "0","1",$(!ServerName),$(!SALogin),$(!SAPassword)
  7348.                 ifstr(i) $(Result) != "NO_SERVER"
  7349.                     LibraryProcedure Result, $(!DLLSQL), SQLExecute $(!SQLShutdown)
  7350.                 endif
  7351.             endif
  7352.         endif
  7353.     endif
  7354.     EndWait
  7355.     Return $(Status)
  7356.     
  7357. [UpdateMSIN]
  7358.     ifstr(i) $(!RemoteComputer) != ""
  7359.         LibraryProcedure NewSQLPath, $(!DLLSQL), StrBeforeAndAfter $(!SQLPath),"AFTER",":"
  7360.         set NewSQLPath = $(!LogicalNTDrive)$(NewSQLPath)
  7361.         set SqlIni = $(!LocalRemoteSystemRoot)"\"$(!SQLBookIni)
  7362.     else
  7363.         set SqlIni = $(!SQLBookIni)
  7364.         set NewSQLPath = $(!SQLPath)
  7365.     endif
  7366.     
  7367.     LibraryProcedure DateStr, $(!DLLSQL),GetDateStr
  7368.     LibraryProcedure Result, $(!DLLSQL), WritePrivProfStr $(!SQLBookSeries),$(!SQLBookB2),$(!SQLBookMVB),$(SqlIni)
  7369.     LibraryProcedure Result, $(!DLLSQL), WritePrivProfStr $(!SQLBookAllTitle),$(!SQLBookMVB),$(!SQLBookMVB),$(SqlIni)
  7370.     ifstr(i) $(!STF_OS) != "NT"
  7371.         LibraryProcedure Result, $(!DLLSQL), WritePrivProfStr $(!SQLBookSetSec),$(!SQLBookLisNa),"SQLUser",$(SqlIni)
  7372.     else
  7373.         LibraryProcedure Result, $(!DLLSQL), WritePrivProfStr $(!SQLBookSetSec),$(!SQLBookLisNa),$(!FullName),$(SqlIni)
  7374.     endif
  7375.     LibraryProcedure Result, $(!DLLSQL), WritePrivProfStr $(!SQLBookSetSec),$(!SQLBookLisOr),$(!OrgName),$(SqlIni)
  7376.     LibraryProcedure Result, $(!DLLSQL), WritePrivProfStr $(!SQLBookSetSec),$(!SQLBookLisVr),$(!SQLBookLisDt),$(SqlIni)
  7377.     LibraryProcedure Result, $(!DLLSQL), WritePrivProfStr $(!SQLBookSetSec),$(!SQLBookLisLr),$(DateStr),$(SqlIni)
  7378.     LibraryProcedure Result, $(!DLLSQL), WritePrivProfStr $(!SQLBookMVB),$(!SQLBookTitle),$(!SQLBooksFullTitle),$(SqlIni)
  7379.     ifstr(i) $(!SQLBooksType) == "1"
  7380.         LibraryProcedure Result, $(!DLLSQL), WritePrivProfStr $(!SQLBookMVB),$(!SQLBookInsType),$(!SQLBookCInsType),$(SqlIni)
  7381.         LibraryProcedure Result, $(!DLLSQL), WritePrivProfStr $(!SQLBookMVB),$(!RegValSysPath),$(NewSQLPath)"\"$(!InstallDir),$(SqlIni)
  7382.     else
  7383.         LibraryProcedure Result, $(!DLLSQL), WritePrivProfStr $(!SQLBookMVB),$(!SQLBookInsType),$(!SQLBookSInsType),$(SqlIni)
  7384.         LibraryProcedure Result, $(!DLLSQL), WritePrivProfStr $(!SQLBookMVB),$(!RegValSysPath),$(!STF_CWDDIR),$(SqlIni)
  7385.     endif
  7386.     LibraryProcedure Result, $(!DLLSQL), WritePrivProfStr $(!SQLBookMVB),$(!SQLBookLDir),$(NewSQLPath)"\"$(!Binaries),$(SqlIni)
  7387.     LibraryProcedure Result, $(!DLLSQL), WritePrivProfStr $(!SQLBookMVB),$(!SQLBookExe),$(NewSQLPath)"\"$(!Binaries),$(SqlIni)
  7388.     Return
  7389.     
  7390. [CheckInstalledScripts]
  7391.     set Status = "STATUS_FAILED"
  7392.     set TempList = $($0)
  7393.     LibraryProcedure Result, $(!DLLSQL), SQLLogin "0","4",$(!ServerName),$(!SALogin),$(!SAPassword)
  7394.     ifstr(i) $(Result) == "NO_SERVER"
  7395.         goto chkinstsp_end
  7396.     endif
  7397.     
  7398.     LibraryProcedure Result, $(!DLLSQL), SQLDBUse $(!Master)
  7399.  
  7400.     ForListDo $(!OptionalScriptList)
  7401.         LibraryProcedure Result, $(!DLLSQL), SQLAddtoCmdBuff $($)
  7402.     EndForListDo
  7403.     
  7404.     LibraryProcedure Result, $(!DLLSQL), SQLExecuteCmdBuff
  7405.     ifstr(i) $(Result) == "BAD_SQL_EXEC"
  7406.         goto chkinstsp_end
  7407.     endif
  7408.     set ListIdx = 0
  7409.     ForListDo $(!OptionalScriptRetList)
  7410.         LibraryProcedure Result, $(!DLLSQL), SQLGetNextResultSet
  7411.         ifstr(i) $(Result) == "BAD_RESULTS"
  7412.             goto chkinstsp_end
  7413.         endif
  7414.         LibraryProcedure Result, $(!DLLSQL), SQLBindColumn "STRINGBIND", "1"
  7415.         LibraryProcedure Result, $(!DLLSQL), SQLNextRow $(!OneNextRow)
  7416.         LibraryProcedure Data, $(!DLLSQL), SQLGetBindingData "1"
  7417.         LibraryProcedure Result, $(!DLLSQL), NonCaseSensSearch $(Data),$($)
  7418.         ifstr(i) $(Result) != "NOT_FOUND"
  7419.             ifstr(i) $(ListIdx) == "0"
  7420.                 set TempList = >( $(TempList), $(!HelpSQL))
  7421.                 set !CheckInstList = >( $(!CheckInstList), $(!SQLHelpSQL))
  7422.                 set !CheckInstRetList = >( $(!CheckInstRetList), $(!RetHelpSQL))
  7423.             endif
  7424.         endif
  7425.         LibraryProcedure Result, $(!DLLSQL), SQLNextRow $(!PurgeRows)
  7426.         set-add ListIdx = $(ListIdx),1
  7427.     EndForListDo
  7428.     LibraryProcedure Result, $(!DLLSQL), SQLLogout
  7429.     set Status = "STATUS_SUCCESSFUL"
  7430. chkinstsp_end =+
  7431.     LibraryProcedure Result, $(!DLLSQL), SQLLogout
  7432.     shell "" CheckMSDB
  7433.     Return $(Status) $(TempList) $($R0)
  7434.     
  7435. [CheckMSDB]
  7436.     set !BMsdb = ""
  7437.     LibraryProcedure Result, $(!DLLSQL), SQLLogin "0","4",$(!ServerName),$(!SALogin),$(!SAPassword)
  7438.     ifstr(i) $(Result) == "NO_SERVER"
  7439.         goto chkmsdb_end
  7440.     endif
  7441.     
  7442.     LibraryProcedure Result, $(!DLLSQL), SQLDBUse $(!Master)
  7443.     LibraryProcedure Result, $(!DLLSQL), SQLAddtoCmdBuff $(!SQLmsdb)
  7444.     LibraryProcedure Result, $(!DLLSQL), SQLExecuteCmdBuff
  7445.     ifstr(i) $(Result) == "BAD_SQL_EXEC"
  7446.         set !BMsdb = "YES"
  7447.         goto chkmsdb_end
  7448.     endif
  7449.     LibraryProcedure Result, $(!DLLSQL), SQLGetNextResultSet
  7450.     ifstr(i) $(Result) == "BAD_RESULTS"
  7451.         set !BMsdb = "YES"
  7452.         goto chkmsdb_end
  7453.     endif
  7454.     LibraryProcedure Result, $(!DLLSQL), SQLBindColumn "STRINGBIND", "1"
  7455.     LibraryProcedure Result, $(!DLLSQL), SQLNextRow $(!OneNextRow)
  7456.     LibraryProcedure Data, $(!DLLSQL), SQLGetBindingData "1"
  7457.     LibraryProcedure Result, $(!DLLSQL), NonCaseSensSearch $(Data),$(!Msdb)
  7458.     ifstr(i) $(Result) == "NOT_FOUND"
  7459.         set !BMsdb = "YES"
  7460.     endif
  7461.     LibraryProcedure Result, $(!DLLSQL), SQLNextRow $(!PurgeRows)
  7462. chkmsdb_end =+
  7463.     LibraryProcedure Result, $(!DLLSQL), SQLLogout
  7464.     Return
  7465.     
  7466. [ExpandMaster]
  7467.     set Status = "STATUS_FAILED"
  7468.     LibraryProcedure Result, $(!DLLSQL), SQLLogin "0","4",$(!ServerName),$(!SALogin),$(!SAPassword)
  7469.     ifstr(i) $(Result) == "NO_SERVER"
  7470.         goto exMaster_end
  7471.     endif
  7472.     
  7473.     LibraryProcedure Result, $(!DLLSQL), SQLDBUse $(!Master)
  7474.     LibraryProcedure Result, $(!DLLSQL), SQLAddtoCmdBuff $(!ExpMstr)$(!SQLMasterSize)
  7475.     LibraryProcedure Result, $(!DLLSQL), SQLExecuteCmdBuff
  7476.     ifstr(i) $(Result) == "BAD_SQL_EXEC"
  7477.         goto exMaster_end
  7478.     endif
  7479.     LibraryProcedure Result, $(!DLLSQL), SQLGetNextResultSet
  7480.     ifstr(i) $(Result) == "BAD_RESULTS"
  7481.         goto exMaster_end
  7482.     endif
  7483.     LibraryProcedure Result, $(!DLLSQL), SQLNextRow $(!PurgeRows)
  7484.     Set Status = "STATUS_SUCCESSFUL"
  7485. exMaster_end =+
  7486.     LibraryProcedure Result, $(!DLLSQL), SQLLogout
  7487.     Return $(Status)
  7488.         
  7489. [CheckInstallSuccess]
  7490.     set Status = "STATUS_FAILED"
  7491.     set !NonCriticalScriptFailure = ""
  7492.     LibraryProcedure Result, $(!DLLSQL), SQLLogin "0","4",$(!ServerName),$(!SALogin),$(!SAPassword)
  7493.     ifstr(i) $(Result) == "NO_SERVER"
  7494.         read-syms NoLoginToSQLServer$(!STF_LANGUAGE)
  7495.         LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)
  7496.         goto chkinst_end
  7497.     endif
  7498.     set CheckNonCritList = $(!NonCriticalCheck)
  7499.     set CheckNonCritList = >( $(CheckNonCritList),$(!Pubs))
  7500.     
  7501.     LibraryProcedure Result, $(!DLLSQL), SQLDBUse $(!Master)
  7502.     ForListDo $(!CheckInstList)
  7503.         LibraryProcedure Result, $(!DLLSQL), SQLAddtoCmdBuff $($)
  7504.     EndForListDo
  7505.     
  7506.     LibraryProcedure Result, $(!DLLSQL), SQLExecuteCmdBuff
  7507.     ifstr(i) $(Result) == "BAD_SQL_EXEC"
  7508.         read-syms SQLExecError$(!STF_LANGUAGE)
  7509.         LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)" CKI #1"$(!LF)
  7510.         LibraryProcedure !AddlText, $(!DLLSQL), SQLGetErrorMsg
  7511.         LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)
  7512.         goto chkinst_end
  7513.     endif
  7514.     ForListDo $(!CheckInstRetList)
  7515.         LibraryProcedure Result, $(!DLLSQL), SQLGetNextResultSet
  7516.         ifstr(i) $(Result) == "BAD_RESULTS"
  7517.             read-syms SQLBadResults$(!STF_LANGUAGE)
  7518.             LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)$($)
  7519.             goto chkinst_end
  7520.         endif
  7521.         LibraryProcedure Result, $(!DLLSQL), SQLBindColumn "STRINGBIND", "1"
  7522.         LibraryProcedure Result, $(!DLLSQL), SQLNextRow $(!OneNextRow)
  7523.         LibraryProcedure Data, $(!DLLSQL), SQLGetBindingData "1"
  7524.         LibraryProcedure Result, $(!DLLSQL), NonCaseSensSearch $(Data),$($)
  7525.         ifstr(i) $(Result) == "NOT_FOUND"
  7526.             ifcontains(i) $($) in $(CheckNonCritList)
  7527.                 set !NonCriticalScriptFailure = "1"
  7528.             else
  7529.                 read-syms SQLBadResults$(!STF_LANGUAGE)
  7530.                 LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)$($)
  7531.                 goto chkinst_end
  7532.             endif
  7533.         endif
  7534.         LibraryProcedure Result, $(!DLLSQL), SQLNextRow $(!PurgeRows)
  7535.     EndForListDo
  7536.     LibraryProcedure Result, $(!DLLSQL), SQLLogout
  7537.     StartWait
  7538.     ProcessExecute Result,"WAIT",$(!SQLPath)"\"$(!Binaries)"\"$(!ISQL)" /n /S"$(!ServerName)" /Usa /Q"sp_check_objects" /o"$(!SQLPath)"\"$(!InstallDir)"\FINALCHK.OUT /P"$(!SAPassword)
  7539.     EndWait
  7540.     
  7541.     ifstr(i) $(Result) == "PROCESS_ERROR"
  7542.         read-syms ProcessExecError$(!STF_LANGUAGE)
  7543.         LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!ISQL)" "$(!AddlText)
  7544.         goto chkinst_end
  7545.     else-ifstr(i) $(Result) != "0"
  7546.         read-syms ProcessRetError$(!STF_LANGUAGE)
  7547.         LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!ISQL)" "$(!AddlText)" "$(Result)
  7548.         goto chkinst_end
  7549.     endif
  7550.     
  7551.     ifstr(i) $($0) != "TRUE"
  7552.         shell "" StopService $(!SQLServerService)
  7553.         ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  7554.             goto chkinst_end
  7555.         endif
  7556.     endif
  7557.     set Status = "STATUS_SUCCESSFUL"
  7558. chkinst_end =+
  7559.     LibraryProcedure Result, $(!DLLSQL), SQLLogout
  7560.     Return $(Status)
  7561.     
  7562. [CreateConfig]
  7563.     set Status = "STATUS_FAILED"
  7564.     LibraryProcedure ConfigFile, $(!DLLSQL), CreateNOpenFile $(!SQLPath)"\"$(!InstallDir)"\"$(!InstConfig)
  7565.     ifstr(i) $(Result) == "Cannot Create File"
  7566.         read-syms CannotCreateFile$(!STF_LANGUAGE)
  7567.         LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)
  7568.         goto crconfig_end
  7569.     endif
  7570.     LibraryProcedure ConfigMemory, $(!DLLSQL), CalcSQLReqMem $(!LogicalSystemMemory)
  7571.     ForListDo $(!ConfigList)
  7572.         LibraryProcedure Result, $(!DLLSQL), WriteToFile $(ConfigFile),$($)
  7573.     EndForListDo
  7574.     LibraryProcedure Temp, $(!DLLSQL), StrBeforeAndAfter $(!MasterDBPath),"AFTER",":"
  7575.     LibraryProcedure NewMasterPath, $(!DLLSQL), AppendToString $(!LogicalDBDrive),$(Temp)
  7576.     LibraryProcedure Result, $(!DLLSQL), WriteToFile $(ConfigFile),$(!SQLPhysName1)$(NewMasterPath)"\"$(!MasterDBFileName)$(!SQLPhysName2)$(!LF)
  7577.     LibraryProcedure Result, $(!DLLSQL), WriteToFile $(ConfigFile),$(!SQLGo)$(!LF)
  7578.     LibraryProcedure Result, $(!DLLSQL), WriteToFile $(ConfigFile),$(!SQLGo)$(!LF)
  7579.     ifstr(i) $($0) != ""
  7580.         ifint $(ConfigMemory) > $($0)
  7581.             LibraryProcedure Result, $(!DLLSQL), WriteToFile $(ConfigFile),$(!SQLMemory)$(ConfigMemory)$(!LF)
  7582.             LibraryProcedure Result, $(!DLLSQL), WriteToFile $(ConfigFile),$(!SQLGo)$(!LF)
  7583.         endif
  7584.     else
  7585.         LibraryProcedure Result, $(!DLLSQL), WriteToFile $(ConfigFile),$(!SQLMemory)$(ConfigMemory)$(!LF)
  7586.         LibraryProcedure Result, $(!DLLSQL), WriteToFile $(ConfigFile),$(!SQLGo)$(!LF)
  7587.     endif
  7588.     LibraryProcedure Result, $(!DLLSQL), WriteToFile $(ConfigFile),$(!SQLAllowUpdatesOff)$(!LF)
  7589.     LibraryProcedure Result, $(!DLLSQL), WriteToFile $(ConfigFile),$(!SQLGo)$(!LF)
  7590.     LibraryProcedure Result, $(!DLLSQL), WriteToFile $(ConfigFile),$(!SQLReconfigure)$(!LF)
  7591.     LibraryProcedure Result, $(!DLLSQL), WriteToFile $(ConfigFile),$(!SQLGo)$(!LF)
  7592.     LibraryProcedure Result, $(!DLLSQL), WriteToFile $(ConfigFile),$(!SQLNameServer1)$(!ComputerName)$(!SQLNameServer2)$(!LF)
  7593.     LibraryProcedure Result, $(!DLLSQL), WriteToFile $(ConfigFile),$(!SQLGo)$(!LF)
  7594.     LibraryProcedure Result, $(!DLLSQL), CloseFile $(ConfigFile)
  7595.     ifstr(i) $(Result) == "DISK_FULL"
  7596.         read-syms DiskFull$(!STF_LANGUAGE)
  7597.         LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)
  7598.         goto crconfig_end
  7599.     endif
  7600.     set Status = "STATUS_SUCCESSFUL"
  7601. crconfig_end =+
  7602.     Return $(Status)
  7603.     
  7604. [InstallScripts]
  7605.     set Status = "STATUS_FAILED"
  7606.     shell "" BuildMSDB
  7607.     ForListDo $(!InstScriptsList)
  7608.         StartWait
  7609.         LibraryProcedure Before, $(!DLLSQL), StrBeforeAndAfter $($),"BEFORE","."
  7610.         ProcessExecute Result,"WAIT",$(!SQLPath)"\"$(!Binaries)"\"$(!ISQL)" /n /S"$(!ServerName)" /Usa /i"$(!SQLPath)"\"$(!InstallDir)"\"$($)" /o"$(!SQLPath)"\"$(!InstallDir)"\"$(Before)".OUT /P"
  7611.         EndWait
  7612.         ifstr(i) $(Result) == "PROCESS_ERROR"
  7613.             read-syms ProcessExecError$(!STF_LANGUAGE)
  7614.             LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!ISQL)" "$(!AddlText)
  7615.             goto instscr_end
  7616.         endif
  7617.     EndForListDo
  7618.     ForListDo $(!AddlScripts)
  7619.         StartWait
  7620.         LibraryProcedure Before, $(!DLLSQL), StrBeforeAndAfter $($),"BEFORE","."
  7621.         ProcessExecute Result,"WAIT",$(!SQLPath)"\"$(!Binaries)"\"$(!ISQL)" /n /S"$(!ServerName)" /Usa /i"$(!SQLPath)"\"$(!InstallDir)"\"$($)" /o"$(!SQLPath)"\"$(!InstallDir)"\"$(Before)".OUT /P"
  7622.         EndWait
  7623.         ifstr(i) $(Result) == "PROCESS_ERROR"
  7624.             read-syms ProcessExecError$(!STF_LANGUAGE)
  7625.             LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!ISQL)" "$(!AddlText)
  7626.             goto instscr_end
  7627.         endif
  7628.     EndForListDo
  7629.     ifcontains(i) $(!InstPubs) in $(!AddlScripts)
  7630.         LibraryProcedure Results $(!DLLSQL) InstallPubsFiles $(!ComputerName),"",$(!SQLPath)"\"$(!InstallDir),$(!PubsFileList)
  7631.     endif
  7632.  
  7633.     set Status = "STATUS_SUCCESSFUL"
  7634. instscr_end =+
  7635.     Return $(Status)
  7636.     
  7637. [InstallWEBProc]
  7638.     set Status = "STATUS_FAILED"
  7639.     set TmpList = {}
  7640.     LibraryProcedure TmpList, $(!DLLSQL), GetDBNames $(!ComputerName), $(!SALogin), $(SAPassword)
  7641.     ForListDo $(TmpList)
  7642.         ProcessExecute Result,"WAIT",$(!SQLPath)"\"$(!Binaries)"\"$(!ISQL)" /n /S"$(!ServerName)" /U"$(!SALogin)" /P"$(!SAPassword)" /i"$(!SQLPath)"\"$(!InstallDir)"\"$(!WEB)" /d"$($)
  7643.         ifstr(i) $(Result) == "PROCESS_ERROR"
  7644.             read-syms ProcessExecError$(!STF_LANGUAGE)
  7645.             LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!ISQL)" "$(!AddlText)
  7646.             goto endInstWEB
  7647.         endif
  7648.     EndForListDo
  7649.     set Status = "STATUS_SUCCESSFUL"
  7650. endInstWEB =+
  7651.     return $(Status)
  7652.  
  7653. [ReIndexServer]
  7654.     set Status = "STATUS_FAILED"
  7655.     
  7656.     LibraryProcedure Result, $(!DLLSQL), Sleepy "5"
  7657.     
  7658.     shell "" StartService $(!SQLServerService)
  7659.     LibraryProcedure Result, $(!DLLSQL), Sleepy "15"
  7660.     LibraryProcedure Result, $(!DLLSQL), SQLLogin "5","3",$(!ServerName),$(!SALogin),$(!SAPassword)
  7661.     ifstr(i) $(Result) == "NO_SERVER"
  7662.         shell "" StartService $(!SQLServerService)
  7663.         LibraryProcedure Result, $(!DLLSQL), Sleepy "10"
  7664.         LibraryProcedure Result, $(!DLLSQL), SQLLogin "5","5",$(!ServerName),$(!SALogin),$(!SAPassword)
  7665.         ifstr(i) $(Result) == "NO_SERVER"
  7666.             read-syms NoLoginToSQLServer$(!STF_LANGUAGE)
  7667.             LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)
  7668.             goto reindex_end
  7669.         endif
  7670.     endif
  7671.     set Status = "STATUS_SUCCESSFUL"
  7672.     
  7673.     LibraryProcedure Result, $(!DLLSQL), SQLLogout
  7674. reindex_end =+
  7675.     Return $(Status)
  7676.     
  7677. [UpdateSystemTables]
  7678.     set Status = "STATUS_FAILED"
  7679.     LibraryProcedure Result, $(!DLLSQL), SQLLogin "0","4",$(!ServerName),$(!SALogin),$(!SAPassword)
  7680.     ifstr(i) $(Result) == "NO_SERVER"
  7681.         read-syms NoLoginToSQLServer$(!STF_LANGUAGE)
  7682.         LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)
  7683.         goto update_end
  7684.     endif
  7685.     LibraryProcedure Result, $(!DLLSQL), SQLExecute $(!UpdateSortOrder1)$(!TheSortConfigValue)$(!UpdateSortOrder2)
  7686.     ifstr(i) $(Result) == "BAD_SQL_EXEC"
  7687.         read-syms SQLExecError$(!STF_LANGUAGE)
  7688.         LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)" UST #1"$(!LF)
  7689.         LibraryProcedure !AddlText, $(!DLLSQL), SQLGetErrorMsg
  7690.         LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)
  7691.         goto update_end
  7692.     endif
  7693.     LibraryProcedure Result, $(!DLLSQL), SQLExecute $(!SQLReconfigure)
  7694.     ifstr(i) $(Result) == "BAD_SQL_EXEC"
  7695.         read-syms SQLExecError$(!STF_LANGUAGE)
  7696.         LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)" UST #2"$(!LF)
  7697.         LibraryProcedure !AddlText, $(!DLLSQL), SQLGetErrorMsg
  7698.         LibraryProcedure !MsgText, $(!DLLSQL), AppendToString $(!MsgText),$(!AddlText)
  7699.         goto update_end
  7700.     endif
  7701.     set Status = "STATUS_SUCCESSFUL"
  7702. update_end =+
  7703.     LibraryProcedure Result, $(!DLLSQL), SQLLogout
  7704.     Return $(Status)
  7705.     
  7706. [DoNetLibPrompts]
  7707.     set Status = "STATUS_FAILED"
  7708.     set FirstUserDefined = 0
  7709.     set CurrentGeneric = 1
  7710.     set NewNetList = {}
  7711.     set NewNetAddresses = {}
  7712.     ForListDo $($0)
  7713.         ifstr(i) $($) == $(!NetLibPipes)
  7714.             ifstr(i) $($1) == "TRUE"
  7715.                 shell "" DoGetNamedPipes
  7716.                 ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  7717.                     set Status = $($R0)
  7718.                     goto end_netlib_prompts
  7719.                 endif
  7720.             endif
  7721.             set NewNetList = >($(NewNetList), $($))
  7722.         else-ifstr(i) $($) == $(!NetLibSPX)
  7723.             shell "" DoGetServiceName
  7724.             ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  7725.                 set Status = $($R0)
  7726.                 goto end_netlib_prompts
  7727.             endif
  7728.             set NewNetList = >($(NewNetList), $($))
  7729.         else-ifstr(i) $($) == $(!NetLibVines)
  7730.             shell "" DoGetStreetName
  7731.             ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  7732.                 set Status = $($R0)
  7733.                 goto end_netlib_prompts
  7734.             endif
  7735.             set NewNetList = >($(NewNetList), $($))
  7736.         else-ifstr(i) $($) == $(!NetLibTCPIP)
  7737.             shell "" DoGetTCPIPSocket
  7738.             ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  7739.                 set Status = $($R0)
  7740.                 goto end_netlib_prompts
  7741.             endif
  7742.             set NewNetList = >($(NewNetList), $($))
  7743.         else-ifstr(i) $($) == $(!NetLibADSP)
  7744.             shell "" DoGetADSPService
  7745.             ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  7746.                 set Status = $($R0)
  7747.                 goto end_netlib_prompts
  7748.             endif
  7749.             set NewNetList = >($(NewNetList), $($))
  7750.         else-ifstr(i) $($) == $(!NetLibDECNet)
  7751.             shell "" DoGetDECNetObjectID
  7752.             ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  7753.                 set Status = $($R0)
  7754.                 goto end_netlib_prompts
  7755.             endif
  7756.             set NewNetList = >($(NewNetList), $($))
  7757.         else-ifstr(i) $($) == $(!NetLibRPC)
  7758.             shell "" DoGetMultiProtEn
  7759.             ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  7760.                 set Status = $($R0)
  7761.                 goto end_netlib_prompts
  7762.             endif
  7763.             set NewNetList = >($(NewNetList), $($))
  7764.         else
  7765.             ifstr(i) $($) == $(!UserDefined)
  7766.                 ifstr(i) $(FirstUserDefined) == "0"
  7767.                     shell "" DoGetSpaceSQLPath GetSQLPathDlg,$(InstallationReqSpace),$(SpaceCost),"1","","",$(!LogicalSQLDrive)
  7768.                     ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  7769.                         set Status = $($R0)
  7770.                         goto end_netlib_prompts
  7771.                     endif
  7772.                     set !SQLPath = $($R1)$($R2)
  7773.                     set !DefSQLPath = $(!SQLPath)
  7774.                     set !CreateSQLPath = $(!SQLPath)
  7775.                     ifstr(i) $(!RemoteComputer) == ""
  7776.                         set !LogicalSQLDrive = $($R1)
  7777.                     endif
  7778.                     set FirstUserDefined = 1
  7779.                 endif
  7780.                 shell "" DoGetNetLibPath
  7781.                 ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  7782.                     set Status = $($R0)
  7783.                     goto end_netlib_prompts
  7784.                 endif
  7785.                 set NewNetList = >($(NewNetList), $(!UserNetLib))
  7786.                 set !UserDefinedName = $(!UserNetLib)
  7787.                 set !NetAddress = ""
  7788.             else
  7789.                 set NewNetList = >($(NewNetList), $($))
  7790.                 set !UserDefinedName = $($)
  7791.                 set !NetAddress = *($(!NetAddresses), $(CurrentGeneric))
  7792.                 set-add CurrentGeneric = $(CurrentGeneric),1
  7793.             endif
  7794.             shell "" DoGetGenericNetAddress
  7795.             ifstr(i) $($R0) != "STATUS_SUCCESSFUL"
  7796.                 set Status = $($R0)
  7797.                 goto end_netlib_prompts
  7798.             endif
  7799.             set NewNetAddresses = >($(NewNetAddresses), $(!NetAddress))
  7800.         endif
  7801.     EndForListDo
  7802.     set Status = "STATUS_SUCCESSFUL"
  7803. end_netlib_prompts =+
  7804.     ifstr(i) $(Status) != "STATUS_SUCCESSFUL"
  7805.         ifstr(i) $($2) == "TRUE"
  7806.             set NewNetList = {}
  7807.             set NewNetAddresses = {}
  7808.         endif
  7809.     endif
  7810.     Return $(Status) $(NewNetList) $(NewNetAddresses)
  7811.     
  7812. [Popup]
  7813.     set tmpvar = $($0)
  7814.     read-syms PopupInfo
  7815.     ui start $(DlgTemplate)
  7816.     ui pop 1
  7817.     Return "STATUS_SUCCESSFUL"
  7818.         
  7819. [AllocateUnusedDrive]
  7820.     set Status = "STATUS_FAILED"
  7821.     set Drive  = ""
  7822.     ifstr(i) $(!STF_UNUSEDDRIVES) == {}
  7823.         goto finish_allocate
  7824.     else-ifstr(i) $(!STF_UNUSEDDRIVES) == ""
  7825.         goto finish_allocate
  7826.     else
  7827.         set NewDriveList = {}
  7828.         ForListDo $(!STF_UNUSEDDRIVES)
  7829.             ifstr(i) $(#) != 1
  7830.                 set NewDriveList = >($(NewDriveList), $($))
  7831.             else
  7832.                 set Drive  = $($)
  7833.                 set Status = "STATUS_SUCCESSFUL"
  7834.             endif
  7835.         EndForListDo
  7836.         set !STF_UNUSEDDRIVES = $(NewDriveList)
  7837.     endif
  7838.     finish_allocate = +
  7839.     Return $(Status) $(Drive)
  7840.         
  7841. [LoadSetupLibrary]
  7842.     LoadLibrary "y" $(!STF_CWDDIR)sqlsetup.dll !DLLSQL
  7843.     exit
  7844.     
  7845. [DispCheckUpgrade]
  7846.     read-syms CheckUpgradeWarning$(!STF_LANGUAGE)
  7847.     Libraryprocedure DlgUpg, $(!DLLSQL), SQLDlgDisplay $(STF_HWND), $(!DlgTemplate), "", $(!SQLDlgNames), "MODAL", ""
  7848.     LibraryProcedure DLGEVENT, $(!DLLSQL), WaitEvent
  7849.     Libraryprocedure Result, $(!DLLSQL), CloseDialog $(DlgUpg)
  7850.     Return
  7851.     
  7852. [LoadLocalLicenseLibrary]
  7853.     LoadLibrary "x" $(!STF_CWDDIR)liccpa.cpl !DLLCPL
  7854.     exit
  7855.     
  7856. [LoadSystemLicenseLibrary]
  7857.     LoadLibrary "x" $(!STF_WINDOWSSYSPATH)"\"liccpa.cpl !DLLCPL
  7858.     exit
  7859.     
  7860. [FreeLicenseLibrary]
  7861.     FreeLibrary $(!DLLCPL)
  7862.     exit
  7863.     
  7864. [LoadSetupWLibrary]
  7865.     LoadLibrary "y" $(!STF_CWDDIR)sqlsetuw.dll !DLLSQL
  7866.     exit
  7867.     
  7868. [FreeSetupLibrary]
  7869.     FreeLibrary $(!DLLSQL)
  7870.     exit
  7871.     
  7872. [LoadPerfLibrary]
  7873.     LoadLibrary "w" $(!SQLPath)"\"$(!Binaries)"\"sqlctr60.dll !PERFHANDLE
  7874.     exit
  7875.     
  7876. [FreePerfLibrary]
  7877.     FreeLibrary $(!PERFHANDLE)
  7878.     exit
  7879.     
  7880. [Install-Shutdown]
  7881.     LibraryProcedure STATUS,$(!DLLSQL),ShutdownSystem "\\"$(!ComputerName)
  7882.     exit
  7883.     
  7884. [LanguageID]
  7885.     ENG
  7886.     
  7887. [LanguageTextENG]
  7888.     "English (American)"
  7889.         
  7890. [LanguageVar]
  7891.     STF_LANGUAGE    =       "" ? $(!DLLSQL) GetLanguage
  7892.     LanguageList    =       ^(LanguageID, 1)
  7893.     
  7894. [DriveTypeVar]
  7895.     DriveType       =       "" ? $(!DLLSQL) GetTypeOfDrive $(DriveToExamine)
  7896.     
  7897. [DetectDirectory]
  7898.     DirectoryThere  =       "-" ? $(!DLLSQL) DoesDirExist $(DEST)
  7899.     
  7900. [NETIsValidName]
  7901.     LibraryProcedure STATUS,$(!DLLSQL),NetNameCheck $(Name)
  7902.     exit
  7903.     
  7904. [CreateSQLDirectory]
  7905.     CreateDir $(!DestPath)
  7906.     exit
  7907.     
  7908. [InstallOneOffFileCopy]
  7909.     AddSectionFilesToCopyList "OneOffCopyFile", $(!SrcCopyPath), $(!DestCopyPath)
  7910.     CopyFilesInCopyList
  7911.     exit
  7912.     
  7913. [InstallMasterFile]
  7914.     SetSilentCopy
  7915.     ifstr(i) $(!TheSortFile) == $(!DefaultSort)
  7916.         AddSectionFilesToCopyList "MasterDefFile", $(!SQLPath)"\"$(!InstallDir), $(!MasterDBPath)
  7917.     else
  7918.         AddSectionFilesToCopyList "MasterAltFile", $(!SQLPath)"\"$(!InstallDir), $(!MasterDBPath)
  7919.     endif
  7920.     CopyFilesInCopyList
  7921.     ClearSilentCopy
  7922.     exit
  7923.         
  7924. [CopyLangFiles]
  7925.     CreateDir $(!DestPath)
  7926.     AddSectionFilesToCopyList "LocaleFile", $(!SrcPath), $(!DestPath)
  7927.     CopyFilesInCopyList
  7928.     exit
  7929.     
  7930. [InstallBaseInstallFiles]
  7931.     ifstr(i) $(GetCost) == ""
  7932.         CreateDir $(!MasterDBPath)
  7933.         CreateDir $(!SQLPath)
  7934.         CreateDir $(!SQLPath)"\"$(!Binaries)
  7935.         CreateDir $(!SQLPath)"\"$(!DOSBinaries)
  7936.         CreateDir $(!SQLPath)"\"$(!InstallDir)
  7937.         CreateDir $(!SQLPath)"\"$(!Binaries)
  7938.         CreateDir $(!SQLPath)"\"$(!Symbols)
  7939.         CreateDir $(!SQLPath)"\"$(!Symbols)"\"$(!Exes)
  7940.         CreateDir $(!SQLPath)"\"$(!Symbols)"\"$(!Binaries)
  7941.         CreateDir $(!SQLPath)"\"$(!CharSets)
  7942.         CreateDir $(!SQLPath)"\"$(!LogDir)
  7943.         CreateDir $(!SQLPath)"\"$(!ReplDir)
  7944.         CreateDir $(!SQLPath)"\"$(!SQLOleDir)
  7945.         CreateDir $(!SQLPath)"\"$(!SQLOleDir)"\"$(!SampleDir)
  7946.         CreateDir $(!SQLPath)"\"$(!SQLOleDir)"\"$(!SampleDir)"\"$(!VBDir)
  7947.         CreateDir $(!SQLPath)"\"$(!CharSets)"\"$(!CP437Dir)
  7948.         CreateDir $(!SQLPath)"\"$(!CharSets)"\"$(!CP850Dir)
  7949.         CreateDir $(!SQLPath)"\"$(!CharSets)"\"$(!ISO1Dir)
  7950.         CreateDir $(!SQLPath)"\"$(!CharSets)"\"$(!CP1250Dir)
  7951.         CreateDir $(!SQLPath)"\"$(!CharSets)"\"$(!CP1251Dir)
  7952.         CreateDir $(!SQLPath)"\"$(!CharSets)"\"$(!CP1253Dir)
  7953.         CreateDir $(!SQLPath)"\"$(!CharSets)"\"$(!CP1254Dir)
  7954.         CreateDir $(!SQLPath)"\"$(!CharSets)"\"$(!CP1255Dir)
  7955.         CreateDir $(!SQLPath)"\"$(!CharSets)"\"$(!CP1256Dir)
  7956.         CreateDir $(!SQLPath)"\"$(!CharSets)"\"$(!CP1257Dir)
  7957.         CreateDir $(!SQLPath)"\"$(!CharSets)"\"$(!CP932Dir)
  7958.         CreateDir $(!SQLPath)"\"$(!CharSets)"\"$(!CP936Dir)
  7959.         CreateDir $(!SQLPath)"\"$(!CharSets)"\"$(!CP949Dir)
  7960.         CreateDir $(!SQLPath)"\"$(!CharSets)"\"$(!CP950Dir)
  7961.         CreateDir $(!SQLPath)"\"$(!SNMPDir)
  7962.         CreateDir $(!SQLPath)"\"$(!BackupDir)
  7963.         ifstr(i) $(!RemoteComputer) != ""
  7964.             ifstr(i) $(!ODBCInstall) == "YES"
  7965.                 CreateDir $(!SQLPath)"\"$(!SQLODBCDir)
  7966.             endif
  7967.         endif
  7968.         ifstr(i) $(!RISCInst) != "YES"
  7969.             CreateDir $(!SystemDirectory)"\..\"$(!MSQueryDir)
  7970.         endif
  7971.     endif
  7972.     ifstr(i) $(!RISCInst) != "YES"
  7973.         AddSectionFilesToCopyList "MSQuery", $(!STF_CWDDIR),$(!SystemDirectory)"\..\"$(!MSQueryDir)
  7974.         AddSectionFilesToCopyList "MSQrySys", $(!STF_CWDDIR),$(!SystemDirectory)
  7975.         AddSectionFilesToCopyList "MSQrySysRoot", $(!STF_CWDDIR),$(!SystemDirectory)"\.."
  7976.         AddSectionFilesToCopyList "WebWriter", $(!STF_CWDDIR), $(!SQLPath)"\"$(!Binaries)
  7977.         AddSectionFilesToCopyList "WebWizSys", $(!STF_CWDDIR),$(!SystemDirectory)
  7978.         AddSectionFilesToCopyList "WebWiz", $(!STF_CWDDIR),$(!SQLPath)"\"$(!Binaries)
  7979.     endif
  7980.     ifstr(i) $(!RdrCopy) != "FALSE"
  7981.         AddSectionFilesToCopyList "NewRDR", $(!STF_CWDDIR),$(!SystemDirectory)"\drivers"
  7982.         AddSectionFilesToCopyList "NewRPC", $(!STF_CWDDIR),$(!SystemDirectory)
  7983.     endif
  7984.     AddSectionFilesToCopyList "BaseInstallExes", $(!STF_CWDDIR), $(!SQLPath)"\"$(!Binaries)
  7985.     AddSectionFilesToCopyList "BaseInstallExeDBGs", $(!STF_CWDDIR), $(!SQLPath)"\"$(!Symbols)"\"$(!Exes)
  7986.     AddSectionFilesToCopyList "DOSInstallExes", $(!STF_CWDDIR), $(!SQLPath)"\"$(!DOSBinaries)
  7987.     AddSectionFilesToCopyList "BaseInstallDLLs", $(!STF_CWDDIR), $(!SQLPath)"\"$(!Binaries)
  7988.     AddSectionFilesToCopyList "BaseInstallDLLDBGs", $(!STF_CWDDIR), $(!SQLPath)"\"$(!Symbols)"\"$(!Binaries)
  7989.     AddSectionFilesToCopyList "MasterFiles", $(!STF_CWDDIR), $(!SQLPath)"\"$(!InstallDir)
  7990.     AddSectionFilesToCopyList "ClientDLLs", $(!STF_CWDDIR), $(!SQLPath)"\"$(!Binaries)
  7991.     AddSectionFilesToCopyList "ClientDLLs", $(!STF_CWDDIR), $(!SystemDirectory)
  7992.     AddSectionFilesToCopyList "ControlPanel", $(!STF_CWDDIR),  $(!SQLPath)"\"$(!Binaries)
  7993.     AddSectionFilesToCopyList "InstallDLLs", $(!SQLPath)"\"$(!Binaries), $(!SystemDirectory)
  7994.     AddSectionFilesToCopyList "InstallExes", $(!SQLPath)"\"$(!Binaries), $(!SystemDirectory)
  7995.     AddSectionFilesToCopyList "BaseInstall", $(!STF_CWDDIR), $(!SQLPath)"\"$(!InstallDir)
  7996.     AddSectionFilesToCopyList "SQLTraceServer", $(!STF_CWDDIR), $(!SQLPath)"\"$(!Binaries)
  7997.     AddSectionFilesToCopyList "SQLTraceClient", $(!STF_CWDDIR), $(!SQLPath)"\"$(!Binaries)
  7998.     AddSectionFilesToCopyList "Charset437", $(!STF_CWDDIR), $(!SQLPath)"\"$(!CharSets)"\"$(!CP437Dir)
  7999.     AddSectionFilesToCopyList "Charset850", $(!STF_CWDDIR), $(!SQLPath)"\"$(!CharSets)"\"$(!CP850Dir)
  8000.     AddSectionFilesToCopyList "CharsetISO", $(!STF_CWDDIR), $(!SQLPath)"\"$(!CharSets)"\"$(!ISO1Dir)
  8001.     AddSectionFilesToCopyList "Charset1250", $(!STF_CWDDIR), $(!SQLPath)"\"$(!CharSets)"\"$(!CP1250Dir)
  8002.     AddSectionFilesToCopyList "Charset1251", $(!STF_CWDDIR), $(!SQLPath)"\"$(!CharSets)"\"$(!CP1251Dir)
  8003.     AddSectionFilesToCopyList "Charset1253", $(!STF_CWDDIR), $(!SQLPath)"\"$(!CharSets)"\"$(!CP1253Dir)
  8004.     AddSectionFilesToCopyList "Charset1254", $(!STF_CWDDIR), $(!SQLPath)"\"$(!CharSets)"\"$(!CP1254Dir)
  8005.     AddSectionFilesToCopyList "Charset1255", $(!STF_CWDDIR), $(!SQLPath)"\"$(!CharSets)"\"$(!CP1255Dir)
  8006.     AddSectionFilesToCopyList "Charset1256", $(!STF_CWDDIR), $(!SQLPath)"\"$(!CharSets)"\"$(!CP1256Dir)
  8007.     AddSectionFilesToCopyList "Charset1257", $(!STF_CWDDIR), $(!SQLPath)"\"$(!CharSets)"\"$(!CP1257Dir)
  8008.      AddSectionFilesToCopyList "Charset932", $(!STF_CWDDIR), $(!SQLPath)"\"$(!CharSets)"\"$(!CP932Dir)
  8009.     AddSectionFilesToCopyList "Charset936", $(!STF_CWDDIR), $(!SQLPath)"\"$(!CharSets)"\"$(!CP936Dir)
  8010.     AddSectionFilesToCopyList "Charset949", $(!STF_CWDDIR), $(!SQLPath)"\"$(!CharSets)"\"$(!CP949Dir)
  8011.     AddSectionFilesToCopyList "Charset950", $(!STF_CWDDIR), $(!SQLPath)"\"$(!CharSets)"\"$(!CP950Dir)
  8012.     AddSectionFilesToCopyList "SNMP", $(!STF_CWDDIR), $(!SQLPath)"\"$(!SNMPDir)
  8013.     ifstr(i) $(!Locale) != ""
  8014.         ifstr(i) $(GetCost) == ""
  8015.             CreateDir $(!SQLPath)"\"$(!LocalesDir)"\"$(!Locale)
  8016.         endif
  8017.         AddSectionFilesToCopyList "LocaleFile", $(!STF_CWDDIR), $(!SQLPath)"\"$(!LocalesDir)"\"$(!Locale)
  8018.     endif
  8019.     AddSectionFilesToCopyList "Util1", $(!STF_CWDDIR), $(!SQLPath)"\"$(!Binaries)
  8020.     AddSectionFilesToCopyList "Util2", $(!STF_CWDDIR), $(!SQLPath)"\"$(!Binaries)
  8021.     AddSectionFilesToCopyList "Util3", $(!STF_CWDDIR), $(!SQLPath)"\"$(!Binaries)
  8022.     AddSectionFilesToCopyList "Util3Read", $(!STF_CWDDIR), $(!SQLPath)"\"$(!SQLOleDir)"\"$(!SampleDir)
  8023.     AddSectionFilesToCopyList "Util3Samp", $(!STF_CWDDIR), $(!SQLPath)"\"$(!SQLOleDir)"\"$(!SampleDir)"\"$(!VBDir)
  8024.     AddSectionFilesToCopyList "Util3Help", $(!STF_CWDDIR), $(!SQLPath)"\"$(!Binaries)
  8025.     AddSectionFilesToCopyList "Util5", $(!STF_CWDDIR), $(!SQLPath)"\"$(!Binaries)
  8026.     AddSectionFilesToCopyList "Util6", $(!STF_CWDDIR), $(!SQLPath)"\"$(!Binaries)
  8027.     ifstr(i) $(!ODBCInstall) == "YES"
  8028.         ifstr(i) $(!RemoteComputer) != ""
  8029.             AddSectionFilesToCopyList "ODBC1", $(!STF_CWDDIR)$(!ODBCDir), $(!SQLPath)"\"$(!SQLODBCDir)
  8030.             AddSectionFilesToCopyList "ODBCRem", $(!STF_CWDDIR), $(!SystemDirectory)
  8031.         endif
  8032.     endif
  8033.     ifstr(i) $(!SQLBooksType) == "1"
  8034.         AddSectionFilesToCopyList "SQLBooks1", $(!STF_CWDDIR),$(!SQLPath)"\"$(!Binaries)
  8035.         AddSectionFilesToCopyList "SQLBooks2", $(!STF_CWDDIR),$(!SQLPath)"\"$(!InstallDir)
  8036.         AddSectionFilesToCopyList "SQLBooks3", $(!SQLBooksDir),$(!SQLPath)"\"$(!InstallDir)
  8037.     else-ifstr(i) $(!SQLBooksType) == "2"
  8038.         AddSectionFilesToCopyList "SQLBooks1", $(!STF_CWDDIR),$(!SQLPath)"\"$(!Binaries)
  8039.         AddSectionFilesToCopyList "SQLBooks2", $(!STF_CWDDIR),$(!SQLPath)"\"$(!InstallDir)
  8040.     endif
  8041.     AddSectionFilesToCopyList "ReplScript", $(!STF_CWDDIR), $(!SQLPath)"\"$(!ReplDir)
  8042.     ifstr(i) $(!RISCInst) != "YES"
  8043.         AddSectionFilesToCopyList "MSDTCServer", $(!STF_CWDDIR), $(!SQLPath)"\"$(!Binaries)
  8044.         AddSectionFilesToCopyList "MSDTCLog", $(!STF_CWDIR), $(!SQLPath)"\"$(!DataDir)
  8045.         AddSectionFilesToCopyList "MSDTCClient", $(!STF_CWDDIR), $(!SQLPath)"\"$(!Binaries)
  8046.         AddSectionFilesToCopyList "MSDTCSys", $(!STF_CWDIR), $(!SystemDirectory)
  8047.     endif
  8048.     ifstr(i) $(GetCost) == ""
  8049.         ifstr(i) $(!RdrCopy) != "FALSE"
  8050.             LibraryProcedure $Results,$(!DLLSQL), FileRenameVersions $(!SystemDirectory)"\drivers\rdr.sys"
  8051.             LibraryProcedure $Results,$(!DLLSQL), FileRenameVersions $(!SystemDirectory)"\rpclts3.dll"
  8052.             LibraryProcedure $Results,$(!DLLSQL), FileRenameVersions $(!SystemDirectory)"\rpclts6.dll"
  8053.         endif
  8054.         CopyFilesInCopyList
  8055.     else
  8056.         GetCopyListSize "SpaceCost","BYTES"
  8057.         ClearCopyList
  8058.     endif
  8059.     exit
  8060.     
  8061. [InstallUtilFiles]
  8062.     ifstr(i) $(GetCost) == ""
  8063.         CreateDir $(!SQLPath)
  8064.         CreateDir $(!SQLPath)"\"$(!Binaries)
  8065.         CreateDir $(!SQLPath)"\"$(!Binaries)
  8066.         ifstr(i) $(!SQLBooksType) == "1"
  8067.             CreateDir $(!SQLPath)"\"$(!InstallDir)
  8068.         else-ifstr(i) $(!SQLBooksType) == "2"
  8069.             CreateDir $(!SQLPath)"\"$(!InstallDir)
  8070.         endif
  8071.         ifcontains(i) $(!SQLStarfterEXE) in $(!UtilFiles)
  8072.             CreateDir $(!SQLPath)"\"$(!SQLOleDir)
  8073.             CreateDir $(!SQLPath)"\"$(!SQLOleDir)"\"$(!SampleDir)
  8074.             CreateDir $(!SQLPath)"\"$(!SQLOleDir)"\"$(!SampleDir)"\"$(!VBDir)
  8075.         endif
  8076.         ifcontains(i) $(!MSQueryEXE) in ($(!UtilsFiles)
  8077.             CreateDir $(!SystemDirectory)"\..\"$(!MSQueryDir)
  8078.         endif
  8079.     endif
  8080.     ifstr(i) $(!RdrCopy) != "FALSE"
  8081.         AddSectionFilesToCopyList "NewRDR", $(!STF_CWDDIR),$(!SystemDirectory)"\drivers"
  8082.         AddSectionFilesToCopyList "NewRPC", $(!STF_CWDDIR),$(!SystemDirectory)
  8083.     endif
  8084.     ifcontains(i) $(!BCP) in $(!UtilFiles)
  8085.         AddSectionFilesToCopyList "Util1", $(!STF_CWDDIR), $(!SQLPath)"\"$(!Binaries)
  8086.     endif
  8087.     ifcontains(i) $(!ISQL) in $(!UtilFiles)
  8088.         AddSectionFilesToCopyList "Util2", $(!STF_CWDDIR), $(!SQLPath)"\"$(!Binaries)
  8089.     endif
  8090.     ifcontains(i) $(!SQLStarfterEXE) in $(!UtilFiles)
  8091.         AddSectionFilesToCopyList "Util3", $(!STF_CWDDIR), $(!SQLPath)"\"$(!Binaries)
  8092.         AddSectionFilesToCopyList "Util3Help", $(!STF_CWDDIR), $(!SQLPath)"\"$(!Binaries)
  8093.         AddSectionFilesToCopyList "Util3DLL", $(!STF_CWDDIR), $(!SQLPath)"\"$(!Binaries)
  8094.         AddSectionFilesToCopyList "Util3Samp", $(!STF_CWDDIR), $(!SQLPath)"\"$(!SQLOleDir)"\"$(!SampleDir)"\"$(!VBDir)
  8095.         AddSectionFilesToCopyList "Util3Read", $(!STF_CWDDIR), $(!SQLPath)"\"$(!SQLOleDir)"\"$(!SampleDir)
  8096.     endif
  8097.     ifcontains(i) $(!SQLSecManEXE) in $(!UtilFiles)
  8098.         AddSectionFilesToCopyList "Util5", $(!STF_CWDDIR), $(!SQLPath)"\"$(!Binaries)
  8099.     endif
  8100.     ifstr(i) $(!RISCInst) != "YES"
  8101.         ifcontains(i) $(!MSQueryEXE) in $(!UtilFiles)
  8102.             AddSectionFilesToCopyList "MSQuery", $(!STF_CWDDIR),$(!SystemDirectory)"\..\"$(!MSQueryDir)
  8103.             AddSectionFilesToCopyList "MSQrySys", $(!STF_CWDDIR),$(!SystemDirectory)
  8104.             AddSectionFilesToCopyList "MSQrySysRoot", $(!STF_CWDDIR),$(!SystemDirectory)"\.."
  8105.         endif
  8106.         ifcontains(i) $(!WebWizardEXE) in $(!UtilFiles)
  8107.             AddSectionFilesToCopyList "WebWiz", $(!STF_CWDDIR), $(!SQLPath)"\"$(!Binaries)
  8108.             AddSectionFilesToCopyList "WebWizSys", $(!STF_CWDDIR), $(!SystemDirectory)
  8109.         endif
  8110.         ifcontains(i) $(!MSDTCClientEXE) in $(!UtilFiles)
  8111.             AddSectionFilesToCopyList "MSDTCClient", $(!STF_CWDDIR), $(!SQLPath)"\"$(!Binaries)
  8112.         endif
  8113.     endif
  8114.     ifcontains(i) $(!SQLTraceEXE) in $(!UtilFiles)
  8115.         AddSectionFilesToCopyList "SQLTraceClient", $(!STF_CWDDIR), $(!SQLPath)"\"$(!Binaries)
  8116.     endif
  8117.     ifcontains(i) $(!ReadPipe) in $(!UtilFiles)
  8118.         AddSectionFilesToCopyList "Util6", $(!STF_CWDDIR), $(!SQLPath)"\"$(!Binaries)
  8119.     endif
  8120.     AddSectionFilesToCopyList "UtilDLLs", $(!STF_CWDDIR), $(!SQLPath)"\"$(!Binaries)
  8121.     AddSectionFilesToCopyList "ClientDLLs", $(!STF_CWDDIR), $(!SQLPath)"\"$(!Binaries)
  8122.     AddSectionFilesToCopyList "ClientDLLs", $(!STF_CWDDIR), $(!SystemDirectory)
  8123.     AddSectionFilesToCopyList "ControlPanel", $(!STF_CWDDIR),  $(!SQLPath)"\"$(!Binaries)
  8124.     AddSectionFilesToCopyList "UtilHelp", $(!STF_CWDDIR), $(!SQLPath)"\"$(!Binaries)
  8125.     ifstr(i) $(!SQLBooksType) == "1"
  8126.         AddSectionFilesToCopyList "SQLBooks1", $(!STF_CWDDIR),$(!SQLPath)"\"$(!Binaries)
  8127.         AddSectionFilesToCopyList "SQLBooks2", $(!STF_CWDDIR), $(!SQLPath)"\"$(!InstallDir)
  8128.         AddSectionFilesToCopyList "SQLBooks3", $(!SQLBooksDir), $(!SQLPath)"\"$(!InstallDir)
  8129.     else-ifstr(i) $(!SQLBooksType) == "2"
  8130.         AddSectionFilesToCopyList "SQLBooks1", $(!STF_CWDDIR),$(!SQLPath)"\"$(!Binaries)
  8131.         AddSectionFilesToCopyList "SQLBooks2", $(!STF_CWDDIR), $(!SQLPath)"\"$(!InstallDir)
  8132.     endif
  8133.         AddSectionFilesToCopyList "RegSvr32", $(!STF_CWDDIR), $(!SQLPath)"\"$(!Binaries)
  8134.     ifstr(i) $(GetCost) == ""
  8135.         ifstr(i) $(!RdrCopy) != "FALSE"
  8136.             LibraryProcedure $Results,$(!DLLSQL), FileRenameVersions $(!SystemDirectory)"\drivers\rdr.sys"
  8137.             LibraryProcedure $Results,$(!DLLSQL), FileRenameVersions $(!SystemDirectory)"\rpclts3.dll"
  8138.             LibraryProcedure $Results,$(!DLLSQL), FileRenameVersions $(!SystemDirectory)"\rpclts6.dll"
  8139.         endif
  8140.         CopyFilesInCopyList
  8141.     else
  8142.         GetCopyListSize "SpaceCost","BYTES"
  8143.         ClearCopyList
  8144.     endif
  8145.     exit
  8146.     
  8147. [OneOffCopyFile]
  8148.     1, $(!OneOffFile)
  8149.     
  8150. [ReadUnusedDrives]
  8151.     !STF_UNUSEDDRIVES = {} ? $(!DLLSQL) GetUnusedDrives
  8152.     
  8153. [GeneralConstants]
  8154.     Radio1          = "1"
  8155.     Radio2          = "2"
  8156.     Radio3          = "3"
  8157.     Radio4          = "4"
  8158.     Radio5          = "5"
  8159.     Radio6          = "6"
  8160.     Radio7          = "7"
  8161.     Radio8          = "8"
  8162.     Radio9          = "9"
  8163.     Chosen          = "ON"
  8164.     NotChosen       = "OFF"
  8165.     InstallDefault  = $(Radio3)
  8166.     SetupOption     = $(InstallDefault)
  8167.     
  8168. [UiVars]
  8169.     SetupLang       = "ENG"
  8170.     ProductVersion  = "6.50.163"
  8171.     OS2             = "OS/2"
  8172.     WindowsNT       = "WINDOWS/NT"
  8173.     MinUpgradeVersion = "6.00.121"
  8174.     PurgeRows       = "1"
  8175.     OneNextRow      = "2"
  8176.     LoginSleepPeriod= "5"
  8177.     LoginSleepRetrys= "5"
  8178.     Primary         = "C:"
  8179.     SQLServerService= "MSSQLServer"
  8180.     SQLOldServerService= "SQLServer"
  8181.     SQLMonitorService="SQLMonitor"
  8182.     SQLSchedulerService="SQLExecutive"
  8183.     SQLOldSchedulerService="SQLScheduler"
  8184.     SQLSchedulerSubService="Subsystems"
  8185.     TCPIPService    = "TCPIP"
  8186.     MSDTCService    = "MSDTC"
  8187.     SNMPService     = "SNMP"
  8188.     LANManService   = "LanmanServer"
  8189.     LANManWksta     = "LanmanWorkstation"
  8190.     RegValMaxThreads = "MaxThreads"
  8191.     RegMaxThreadDefault = "50"
  8192.     AdministratorsGroup = {"SYSTEM","Administrators"}
  8193.     SystemGroup     = "SYSTEM"
  8194.     DefGuest        = "guest"
  8195.     DOSBinaries     = "BIN"
  8196.     Binaries        = "BINN"
  8197.     Exes            = "EXE"
  8198.     DataDir         = "DATA"
  8199.     DLLs            = "DLL"
  8200.     Symbols         = "SYMBOLS"
  8201.     UpgradeDirPath  = "CHARSETS\CP850"
  8202.     CharSets        = "CHARSETS"
  8203.     InstallDir      = "INSTALL"
  8204.     LogDir          = "LOG"
  8205.     DataDir         = "DATA"
  8206.     ReplDir         = "REPLDATA"
  8207.     SystemDir       = "SYSTEM32"
  8208.     System16Dir     = "SYSTEM"
  8209.     ExtendedSpExDir = "EXTENDSP"
  8210.     IncludeDir      = "INCLUDE"
  8211.     SampleDir       = "SAMPLES"
  8212.     SQLOleDir    = "SQLOLE"
  8213.     VBDir        = "VB"
  8214.     LibDir          = "LIB"
  8215.     ODBCDir         = "ODBC"
  8216.     SQLODBCDir      = "SQLODBC"
  8217.     ODBCDrv         = "SQL Server"
  8218.     CP437Dir        = "CP437"
  8219.     CP850Dir        = "CP850"
  8220.     ISO1Dir         = "CPISO"
  8221.     CP1250Dir       = "CP1250"
  8222.     CP1251Dir       = "CP1251"
  8223.     CP1253Dir       = "CP1253"
  8224.     CP1254Dir       = "CP1254"
  8225.     CP1255Dir       = "CP1255"
  8226.     CP1256Dir       = "CP1256"
  8227.     CP1257Dir       = "CP1257"
  8228.     CP932Dir        = "CP932"
  8229.     CP936Dir        = "CP936"
  8230.     CP949Dir        = "CP949"
  8231.     CP950Dir        = "CP950"
  8232.     MSDTCDir        = "MSDTC"
  8233.     SNMPDir         = "SNMP"
  8234.     BackupDir       = "BACKUP"
  8235.     MSQueryDir      = "MSAPPS\MSQuery"
  8236.     LocalesDir      = "LOCALES"
  8237.     ErrorLog        = "ERRORLOG"
  8238.     CharSet         = "CHARSET.EXE"
  8239.     BCP             = "BCP.EXE"
  8240.     SetupEXE        = "SETUP.EXE"
  8241.     ConsoleEXE      = "CONSOLE.EXE"
  8242.     StopLite        = "SQLMGR.EXE"
  8243.     ReadPipe        = "READPIPE.EXE"
  8244.     LangInst        = "LANGINST.EXE"
  8245.     SQLTransferEXE  = "SQLXFR.EXE"
  8246.     WebWizardEXE    = "WEBWIZ.EXE"
  8247.     SQLTraceEXE        = "SQLTRACE.EXE"
  8248.     PerfMonEXE      = "PERFMON.EXE"
  8249.     SQLStarfterEXE  = "SQLEW.EXE"
  8250.     SQLClientEXE    = "WINDBVER.EXE"
  8251.     SQLSecManEXE    = "SQSECMGR.EXE"
  8252.     ISQLWEXE        = "ISQLW.EXE"
  8253.     SQLMonitorEXE   = "SQLMONTR.EXE"
  8254.     SQLCtrsPMC      = "SQLCTRS.PMC"
  8255.     SQLCtrs         = "SQLCTR60"
  8256.     SQLCtrsDLL      = "SQLCTR60.DLL"
  8257.     OldSQLCtrs    = "SQLCTRS"
  8258.     DefLangFile     = "SERVER.LOC"
  8259.     EventCtrsDLL    = "EVNTCT60.DLL"
  8260.     StarFterOle     = "SQLOLE.REG"
  8261.     MSDTCOle        = "MSDTC.REG"
  8262.     RegEdit         = "REGEDIT.EXE"
  8263.     ISQL            = "ISQL.EXE"
  8264.     ISQLOut         = "ISQL.OUT"
  8265.     HelpSQLHLP      = "HELPSQL.HLP"
  8266.     HelpAdmin       = "SQLADMIN.HLP"
  8267.     HelpObject      = "SQLOBJ.HLP"
  8268.     HelpSQLNTSetup  = "SQLSETUP.HLP"
  8269.     HelpODBCInst    = "DRVSSRVR.HLP"
  8270.     SQLOleHlp       = "SQLOLE.HLP"
  8271.     SQLOle32    = "SQLOLE32.DLL"
  8272.     ODSOle32        =   "ODSOLE32.DLL"
  8273.     WinHelpEXE      = "WINHLP32.EXE"
  8274.     Win95HelpEXE      = "WINHELP.EXE"
  8275.     NotePadEXE      = "NOTEPAD.EXE"
  8276.     SQLEventDLL     = "SQLEVN60.DLL"
  8277.     SQLSchEventDLL  = "SQLEXEC.DLL"
  8278.     SQLCmdExecDLL   = "CMDEXEC.DLL"
  8279.     SQLReplDLL      = "SQLREPL.DLL"
  8280.     MSVCModule      = "MSVCRT40.DLL"
  8281.     MSVC20Module    = "MSVCRT20.DLL"
  8282.     MFCModule       = "MFC40.DLL"
  8283.     CTL3DModule     = "CTL3D32.DLL"
  8284.     MasterDB        = "MASTER.DAT"
  8285.     DefMasterDB     = $(!MasterDB)
  8286.     SQLServer       = "SQLSERVR.EXE"
  8287.     SQLSchedulerEXE = "SQLEXEC.EXE"
  8288.     MSDTCEXE        = "MSDTC.EXE"
  8289.     MSDTCDacEXE     = "DAC.EXE"
  8290.     MSDTCServerEXE  = "SERVER.EXE"
  8291.     MSDTCClientEXE  = "CLIENT.EXE"
  8292.     MSDTCSrv1       = "SRV1"
  8293.     MSDTCSrv2       = "SRV2"
  8294.     MSDTCSrv3       = "SRV3"
  8295.     MSQueryEXE      = "MSQRY32.EXE"
  8296.     CMDExec         = "CMDEXEC.DLL"
  8297.     SQLOut          = "SQLSERVR.OUT"
  8298.     UpgradeOut      = "CHKUPG.OUT"
  8299.     LangInstOut     = "LANGINST.OUT"
  8300.     CharSetOut      = "CHARSET.OUT"
  8301.     InstConfig      = "CONFIG.SQL"
  8302.     DropAll         = "DROPALL.SQL"
  8303.     InstUpg         = "UPGRADE1.SQL"
  8304.     InstChkObj      = "CHECKOBJ.SQL"
  8305.     InstMsgs        = "MESSAGES.SQL"
  8306.     InstSptVal      = "U_TABLES.SQL"
  8307.     InstSysCfg      = "CONFIGUR.SQL"
  8308.     InstProc        = "PROCSYST.SQL"
  8309.     InstRepl        = "INSTREPL.SQL"
  8310.     InstEarly       = "EARLY1.SQL"
  8311.     InstSch         = "INSTMSDB.SQL"
  8312.     InstSmsg        = "SERVMSGS.SQL"
  8313.     InstXPStar      = "XPSTAR.SQL"
  8314.     InstSQLOle      = "SQLOLE60.SQL"
  8315.     InstOM          = "OBJECT60.SQL"
  8316.     InstAdmin       = "ADMIN60.SQL"
  8317.     UnAdmin         = "UNADMIN.SQL"
  8318.     UnObject        = "UNOBJ.SQL"
  8319.     TempSp          = "TEMPSP.SQL"
  8320.     InstCat         = "INSTCAT.SQL"
  8321.     HelpSQL         = "HELPSQL.SQL"
  8322.     InstPubs        = "INSTPUBS.SQL"
  8323.     WEB             = "WEB.SQL"
  8324.     ExpandEXE       = "EXPAND.EXE"
  8325.     SQLSNMPDLL      = "SQLSNMP.DLL"
  8326.     UpdateSortOrder1= "update master.dbo.sysconfigures set value = "
  8327.     UpdateSortOrder2= ", config = 1123 where config = 123"
  8328.     SQLGo           = "go"
  8329.     SQLReconfigure  = "reconfigure with override"
  8330.     SQLShutdown     = "shutdown with nowait"
  8331.     SQLAddLogin     = "sp_addlogin "
  8332.     SQLAllowUpdatesOn= "sp_configure 'allow_updates', 1"
  8333.     SQLUseMaster    = "use master"
  8334.     SQLPhysName1    = "update master.dbo.sysdevices set phyname='"
  8335.     SQLPhysName2    = "' where name = 'master'"
  8336.     SQLRecoveryInterval="sp_configure 'recovery interval', 5"
  8337.     SQLAllowUpdatesOff= "sp_configure 'allow updates', 0"
  8338.     SQLUserConns    = "sp_configure 'user connections', 20"
  8339.     SQLMemory       = "sp_configure 'memory', "
  8340.     SQLOpenDBs      = "sp_configure 'open databases', 20"
  8341.     SQLLocks        = "sp_configure 'locks', 5000"
  8342.     SQLOpenObjs     = "sp_configure 'open objects', 500"
  8343.     SQLProcCache    = "sp_configure 'procedure cache', 30"
  8344.     SQLFillFactor   = "sp_configure 'fill factor', 0"
  8345.     SQLDBSize       = "sp_configure 'database size', 2"
  8346.     SQLMediaRetent  = "sp_configure 'media retention', 0"
  8347.     SQLRecoveryFlags= "sp_configure 'recovery flags', 0"
  8348.     SQLNameServer1  = "sp_addserver "
  8349.     SQLNameServer2  = ",local"
  8350.     SQLGrantAdmin   = "xp_grantlogin 'Administrators',admin"
  8351.     SQLSetLang      = "sp_configure 'default language', 1"
  8352.     SQLGetMemory    = "select value from master.dbo.sysconfigures where config = 104"
  8353.     SQLspWho        = "select name from master.dbo.sysobjects where name = 'sp_who' "
  8354.     SQLSPTValues    = "select name from master.dbo.sysobjects where name = 'spt_values' "
  8355.     SQLAddXProc     = "select name from master.dbo.sysobjects where name = 'sp_addextendedproc' "
  8356.     SQLCtrsUsers    = "select name from master.dbo.sysobjects where name = 'MS_sqlctrs_users' "
  8357.     SQLInfoExt      = "select name from master.dbo.sysobjects where name = 'spt_datatype_info_ext' "
  8358.     SQLSpecCols     = "select name from master.dbo.sysobjects where name = 'sp_special_columns' "
  8359.     SQLXPStar1      = "select name from master.dbo.sysobjects where name = 'xp_regread'"
  8360.     SQLXPStar2      = "select name from master.dbo.sysobjects where name = 'xp_subdirs'"
  8361.     SQLOle1         = "select name from master.dbo.sysobjects where name = 'sp_MShelpcolumns'"
  8362.     SQLHelpSQL      = "select name from master.dbo.sysobjects where name = 'sp_helpsql'"
  8363.     SQLCheckVersion = "select value from master.dbo.sysconfigures where config = 122"
  8364.     SQLGetMasterOS  = "select name from master.dbo.spt_values where low = 2048"
  8365.     SQLCheckRO      = "select count(*) from master.dbo.sysdatabases where status & 1024 > 0"
  8366.     SQLCheckMasterSpace="declare @dbsize int "$(!LF)+
  8367.     "declare @dbreserve int "$(!LF)+
  8368.     "select @dbsize = (sum(size) * 2048) / 1024 from master.dbo.sysusages where dbid = 1 and (segmap = 7 or segmap = 3) "$(!LF)+
  8369.     "select @dbreserve = (sum(reserved) * 2048) / 1024 from master.dbo.sysindexes where indid in (0, 1, 255) "$(!LF)+
  8370.     "select @dbsize - @dbreserve"$(!LF)+
  8371.     "go "
  8372.     SQLCheckSuspect = "select count(*) from master.dbo.sysdatabases where status & 256 > 0"
  8373.     SQLGetConfOpen  = "select value from master.dbo.syscurconfigs where config=105"
  8374.     SQLGetNumDBs    = "select count(*) from master.dbo.sysdatabases"
  8375.     SQLUpgObjects   = "declare @needed int"$(!LF)+
  8376.     "declare @got int"$(!LF)+
  8377.     "declare @databases int"$(!LF)+
  8378.     "select @got = value from master..syscurconfigs where config=107"$(!LF)+
  8379.     "select @databases = count(*) from master..sysdatabases"$(!LF)+
  8380.     "select @needed = 13 + 13 * @databases +20"$(!LF)+
  8381.     "if(@needed > @got and @needed > 100)"$(!LF)+
  8382.     "begin exec sp_configure 'open objects',@needed"$(!LF)+
  8383.     "reconfigure with override end"
  8384.     SQLUpgConfigMem = "declare @cfgmem int"$(!LF)+
  8385.     "declare @numusers int"$(!LF)+
  8386.     "declare @opendb   float"$(!LF)+
  8387.     "declare @locks    float"$(!LF)+
  8388.     "declare @openobj  float"$(!LF)+
  8389.     "declare @memneed  int"$(!LF)+
  8390.     "select @cfgmem= value from master.dbo.sysconfigures where config=104"$(!LF)+
  8391.     "select @numusers= 19 * value from master.dbo.sysconfigures where config=103"$(!LF)+
  8392.     "select @opendb= .5 * value from master.dbo.sysconfigures where config=105"$(!LF)+
  8393.     "select @openobj= .04 * value from master.dbo.sysconfigures where config=107"$(!LF)+
  8394.     "select @locks=  .0156 * value from master.dbo.sysconfigures where config=106"$(!LF)+
  8395.     "select  @memneed =  2300 + @numusers + @opendb + @openobj + @locks"$(!LF)+
  8396.     "if @memneed < 2800 select @memneed = 2800"$(!LF)+
  8397.     "if @memneed > @cfgmem begin"$(!LF)+
  8398.     "exec sp_configure 'memory',@memneed"$(!LF)+
  8399.     "reconfigure with override end"
  8400.     SQLSelectDBNames = "SELECT name FROM master.dbo.sysdatabases"
  8401.  
  8402.     SQLDiskInit = "DISK INIT NAME = "
  8403.     MSDBData    = "MSDBData"
  8404.     Physname     = "PHYSNAME='"
  8405.     MSDBDataDat = "MSDB.DAT"
  8406.     VdevDatPlus  = "VDEVNO="
  8407.     VdevDatNo   =  ",SIZE=3072"
  8408.     MSDBLog     = "MSDBLog"
  8409.     MSDBDataLog = "MSDBLOG.DAT"
  8410.     VdevLogPlus  = "VDEVNO="
  8411.     VdevLogNo    = ",SIZE=1024"
  8412.     SQLGetDevNo  = "declare @i int select @i = 127 while exists (select * from master.dbo.sysdevices where (low/0x01000000)&0xff = @i) and @i <> 0 select @i = @i - 1 if @i = 0 select -1 else select @i"
  8413.     
  8414.     CheckLogin    = "select name from master.dbo.syslogins where name = "
  8415.     SQLmsdb         = "select name from master.dbo.sysdatabases where name = 'msdb'"
  8416.     Msdb            = "msdb"
  8417.     InstallSetInstld= {"1","3"}
  8418.     InstallSetDual=   {"3"}
  8419.     InstallSet      = {"4","5","6","7","8","9","10"}
  8420.     CompleteInstSet = {"1","2","3","4","5","6","7","8","9","10"}
  8421.     EvalSet = {"1", "2", "3"}
  8422.     SupportedRemoteShares = {"C","D","E","F","G","H","I","J","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z"}
  8423.     PubsFileList = { "1622","5LAKES.BMP","1389","ALGODATA.BMP","0877","BINNET.BMP","9901","GGGG.BMP","9999","LUCERNE.BMP","0736","NEWMOON.BMP","1756","RAMONA.BMP","9952","SCOOTNEY.BMP",+
  8424.     "1622","5LAKES.TXT","1389","ALGODATA.TXT","0877","BINNET.TXT","9901","GGGG.TXT","9999","LUCERNE.TXT","1756","RAMONA.TXT","9952","SCOOTNEY.TXT","0736","NEWMOON.TXT" }
  8425.     NetLibPipes     = "SSNMPN60"
  8426.     NetLibSPX       = "SSMSSP60"
  8427.     NetLibVines     = "SSMSVI60"
  8428.     NetLibTCPIP     = "SSMSSO60"
  8429.     NetLibADSP      = "SSMSAD60"
  8430.     NetLibDECNet    = "SSMSDE60"
  8431.     NetLibRPC       = "SSMSRP60"
  8432.     ClientLibPipes  = "DBNMPNTW"
  8433.     ClientLibSPX    = "DBMSSPXN"
  8434.     ClientLibVine   = "DBMSVINN"
  8435.     ClientLibTCPIP  = "DBMSSOCN"
  8436.     DBLibDLL        = "NTWDBLIB.DLL"
  8437.     DefTCPIPSocket  = "1433"
  8438.     DefMonTCPIPSocket = "1434"
  8439.     DefDECNetObjectID = "#150"
  8440.     ConsolePipe     = "\\.\pipe\sql\console"
  8441.     MonitorPipe     = "\\.\pipe\winsql\backup"
  8442.     DefListenOn     = {"SSNMPN60,\\.\pipe\sql\query"}
  8443.     SvrPipe         = "\\.\pipe\sql\query"
  8444.     MonNetLibPipeCon= "?1:\\?1\pipe\winsql\backup"
  8445.     MonNetLibSPXCon = "?1:?1_mon"
  8446.     MonNetLibVineCon= "?1@?2:?1_mon?2"
  8447.     MonNetLibTCPIPCon= "?1,?2:?1,"$(!DefMonTCPIPSocket)
  8448.     DefSvcMgrServices={$(!SQLServerService),$(!SQLSchedulerService),$(!MSDTCService)}
  8449.     DefScriptList   = {$(!InstPubs),$(!HelpSQL)}
  8450.     NetLibDefList   = {$(!NetLibPipes)}
  8451.     NetLibList      = {$(!NetLibPipes)}
  8452.     
  8453.     AddlScripts     = {}
  8454.     NetSelList      = {}
  8455.     ConfigList      = {$(SQLAllowUpdatesOn)$(!LF),$(!SQLGo)$(!LF)$(!SQLReconfigure)$(!LF),$(!SQLGo)$(!LF)$(!SQLUseMaster)$(!LF)$(!SQLGo)$(!LF)}
  8456.     DelDLLList      = {"opends60.dll","ssnmpn60.dll","ssmsso60.dll","sqlevn60.dll","xpsql60.dll","xpstar.dll","charset.exe", "sqlsvc32.dll"}
  8457.     DelODBCDLLList  = "instodbc.dll"
  8458.     ClientDLLList   = {$(!ClientLibPipes)".DLL",$(!ClientLibSPX)".DLL",$(!ClientLibVine)".DLL",$(!ClientLibTCPIP)".DLL",$(!DBLibDLL)}
  8459.     
  8460.     CheckInstDefList= {$(!SQLspWho),$(!SQLSPTValues),$(!SQLAddXProc),$(!SQLCtrsUsers),$(!SQLInfoExt),+
  8461.     $(!SQLSpecCols),$(!SQLXPStar1),$(!SQLXPStar2),$(!SQLOle1)}
  8462.     CheckInstDefRetList= {"sp_who","spt_values","sp_addextendedproc","MS_sqlctrs_users",+
  8463.     "spt_datatype_info_ext","sp_special_columns","xp_regread","xp_subdirs","sp_MShelpcolumns"}
  8464.     
  8465.     NonCriticalCheck= {"sp_MSdevice_list","sp_MSuser_info","sp_helpsql"}
  8466.     OptionalScriptRetList= {"sp_helpsql"}
  8467.     OptionalScriptList={$(!SQLObject1),$(!SQLHelpSQL)}
  8468.     CheckInstList   = $(!CheckInstDefList)
  8469.     CheckInstRetList= $(!CheckInstDefRetList)
  8470.     
  8471.     XpStarChk1      = "xp_regread"
  8472.     XpStarChk2      = "xp_subdirs"
  8473.     SQLOleChk1      = "sp_MShelpcolumns"
  8474.     Master          = "master"
  8475.     RetHelpSQL      = "sp_helpsql"
  8476.     
  8477.     STF_WINDOWSSYSPATH = "" ? $(!DLLSQL) GetWindowsNtSysDir
  8478.     STF_WINDOWSPATH = "" ? $(!DLLSQL) GetWindowsNtDir
  8479.     STF_UNUSEDDRIVES = {} ? $(!DLLSQL) GetUnusedDrives
  8480.     
  8481.     MsgText         =       ""
  8482.     InstallType     =       ""
  8483.     DlgHandle       =       ""
  8484.     
  8485.     TheCharSet      =       ""
  8486.     TheCharSetPath  =       ""
  8487.     TheSortFile     =       ""
  8488.     DefaultSort     =       "nocase.iso"
  8489.     TheSortConfigValue=     ""
  8490.     ComputerName    =       ""
  8491.     Registration    =       ""
  8492.     Owner           =       ""
  8493.     ProductID       =       ""
  8494.     SALogin         =       "sa"
  8495.     SAPassword      =       ""
  8496.     YesNoQ          =       ""
  8497.     CreateSQLPath   =       ""
  8498.     OrgName         =       ""
  8499.     FullName        =       ""
  8500.     SingleUserMode  =       "-m"
  8501.     WasSingleMode   =       ""
  8502.     MachineName     =       ""
  8503.     MasterDBPath    =       ""
  8504.     DefMasterPath   =       "DATA"
  8505.     CreateMasterPath=       "NO"
  8506.     UserDefined     =       "UU"
  8507.     UserProvided    =       "PP"
  8508.     DefSQLStub      =       "MSSQL"
  8509.     DefNETPath      =       "A:\"
  8510.     CreateSQLPath   =       "NO"
  8511.     MasterExistCheck=       "NO"
  8512.     DefMasterSize   =       "25"
  8513.     SQLMasterSize   =       ""
  8514.     MinMasterSize   =       "25"
  8515.     NETPath         =       ""
  8516.     CreateNETPath   =       "NO"
  8517.     DefSocketNumber =       ""
  8518.     DefTapeDev      =       "\DEVICE\Tape0"
  8519.     DefSecMap1      =       "\"
  8520.     DefSecMap2      =       "-"
  8521.     DefSecMap3      =       " "
  8522.     SecTokDomainSep =       "\"
  8523.     SecTokSpace     =       " "
  8524.     CopyMailInfo    =       ""
  8525.     UserName        =       ""
  8526.     UserPassword    =       ""
  8527.     CurInstalledVer =       ""
  8528.     SQLBooksType    =       "1"
  8529.     BMsdb           =       ""
  8530.     
  8531.     RegTypeString   =       "REG_SZ"
  8532.     RegTypeExpString=       "REG_EXPAND_SZ"
  8533.     RegTypeMulti    =       "REG_MULTI_SZ"
  8534.     RegTypeDWord    =       "REG_DWORD"
  8535.     RegValRegOwner  =       "RegisteredOwner"
  8536.     RegValRegOrg    =       "RegisteredOrganization"
  8537.     RegValRegPID    =       "RegisteredProductID"
  8538.     RegValSoftType  =       "SoftwareType"
  8539.     RegValSerialNumber=     "SerialNumber"
  8540.     RegValVersion   =       "CurrentVersion"
  8541.     RegValListenOn  =       "ListenOn"
  8542.     RegValConsole   =       "Console"
  8543.     RegValTapeWait  =       "Tapeloadwaittime"
  8544.     RegValParameter =       "SQLArg"
  8545.     RegValSQLPath   =       "SQLPath"
  8546.     RegValSvcMgrVerify =    "Action Verify"
  8547.     RegValSvcMgrSvcs=       "Services"
  8548.     RegValSvcMgrRemote =    "Remote"
  8549.     RegValSvcMgrDefSvc =    "DefaultSvc"
  8550.     RegValPathName  =       "Pathname"
  8551.     
  8552.     RegSQLSysType   =       "System"
  8553.     RegSWMS         =       "SOFTWARE\Microsoft"
  8554.     RegEventAppLog  =       "SYSTEM\CurrentControlSet\Services\EventLog\Application"
  8555.     RegLMSvrParams  =       "SYSTEM\CurrentControlSet\Services\LanmanServer"
  8556.     RegTCPIPService =       "SYSTEM\CurrentControlSet\Services\Tcpip"
  8557.     RegSCM          =       "SYSTEM\CurrentControlSet\Services"
  8558.     RegSystemGrpOrder =     "SYSTEM\CurrentControlSet\Control\ServiceGroupOrder"
  8559.     RegSystemPaths  =       "SYSTEM\CurrentControlSet\Control\Session Manager\Environment"
  8560.     RegMManagement  =       "SYSTEM\CurrentControlSet\Control\Session Manager\Memory Management"
  8561.     RegPriorityCtrl =       "SYSTEM\CurrentControlSet\Control\PriorityControl"
  8562.     RegLicInfoKey   =       "SYSTEM\CurrentControlSet\Services\LicenseInfo"
  8563.     RegSQLLicInfoKey   =       "SYSTEM\CurrentControlSet\Services\LicenseInfo\MSSQL6.50"
  8564.     RegSQL60LicInfoKey  =   "SYSTEM\CurrentControlSet\Services\LicenseInfo\MSSQL6.00"
  8565.     SMSVersionKey   =       "SOFTWARE\Microsoft\SMS\Setup"
  8566.     RegOLE          =       "SOFTWARE\Classes"
  8567.     RegCLSID        =       "CLSID"
  8568.     RegSNMPAgents      =    "SNMP\Parameters\ExtensionAgents"
  8569.     
  8570.     RegValLicMode   =       "Mode"
  8571.     RegValLicCon    =       "ConcurrentLimit"
  8572.     RegValLicFlip   =       "FlipAllow"
  8573.     RegValLicDspName =      "DisplayName"
  8574.     RegValLicFDspName =     "FamilyDisplayName"
  8575.     RegLicDspName   =       "Microsoft SQL Server 6.5"
  8576.     RegLicFDspName  =       "Microsoft SQL Server"
  8577.     RegLMSize       =       "Size"
  8578.     RegMMSystemCache=       "LargeSystemCache"
  8579.     RegUserPaths    =       "Environment"
  8580.     RegSysDOSDev    =       "DOS Devices"
  8581.     RegSysPriority  =       "Win32PrioritySeparation"
  8582.     RegValGrpOrderList =    "List"
  8583.     RegValTape0     =       "Tape0"
  8584.     RegValELogMsgFile =     "EventMessageFile"
  8585.     RegValELogTypes =       "TypesSupported"
  8586.     RegValELogCMsgFile =    "CategoryMessageFile"
  8587.     RegValELogCCount =      "CategoryCount"
  8588.     
  8589.     RegValLMSvrAnno =       "Lmannounce"
  8590.     RegValSysPath   =       "Path"
  8591.     RegSQLServer    =       "SOFTWARE\Microsoft\MSSQLServer"
  8592.     RegOldSQLServer =       "SOFTWARE\Microsoft\SQLServer"
  8593.     RegOldSQLServerServer = "SOFTWARE\Microsoft\SQLServer\Server"
  8594.     RegSQLServer60Server =  "SOFTWARE\Microsoft\SQLServer60\SQL Service Manager"
  8595.     RegSQLServerServer =    "SOFTWARE\Microsoft\MSSQLServer\MSSQLServer"
  8596.     RegOldSQLClient =       "SOFTWARE\Microsoft\SQLServer\Client"
  8597.     RegSQLClient    =       "SOFTWARE\Microsoft\MSSQLServer\Client"
  8598.     RegSQLScheduler =       "SOFTWARE\Microsoft\MSSQLServer\SQLExecutive"
  8599.     RegSQLReplication =     "SOFTWARE\Microsoft\MSSQLServer\Replication"
  8600.     
  8601.     RegSQLAdmin     =       "SQL Administrator"
  8602.     RegISQLW        =       "ISQL/w"
  8603.     RegSQLOM        =       "SQL Object Manager"
  8604.     RegStarFighter  =       "SQLEW"
  8605.     RegSecMan       =       "SQL Security Manager"
  8606.     RegSQLSetup     =       "SOFTWARE\Microsoft\MSSQLServer\Setup"
  8607.     RegSQLSNMP      =       "SNMP"
  8608.     RegCurrentVer   =       "CurrentVersion"
  8609.     RegSQLClientSetup     = "SOFTWARE\Microsoft\MSSQLServer\ClientSetup"
  8610.     RegOldSQLSetup  =       "SOFTWARE\Microsoft\SQLServer\Setup"
  8611.     RegSQLSetupKey  =       "Setup"
  8612.     RegSQLClientSetupKey  = "ClientSetup"
  8613.     RegSecLoginMode =       "LoginMode"
  8614.     
  8615.     RegSQLEvaluation =      "SOFTWARE\Microsoft\Windows\CurrentVersion"
  8616.     RegSQLEval = "ESvQaLl"
  8617.     
  8618.     RegValSQLReplDir =      "Directory"
  8619.     RegValSQLReplDB =       "DistributionDB"
  8620.     RegValSQLReplication =  "Replication"
  8621.     RegValRealTime  =       "RealTime"
  8622.     RegValSMPStat   =       "SMPStat"
  8623.     RegValSqlMailPair =     "SQLMAP60,startmail"
  8624.     RegValMailEnabled =     "StartupHandlers"
  8625.     MSMailUser      =       ""
  8626.     MSMailPwd       =       ""
  8627.     RegValMSMailUser =      "MailAccountName"
  8628.     RegValMSMailPwd  =      "MailPassword"
  8629.     RegSecDefAccount =      "DefaultLogin"
  8630.     RegSecDefDomain  =      "DefaultDomain"
  8631.     RegSecAuditLevel =      "AuditLevel"
  8632.     RegSecHostname  =       "SetHostname"
  8633.     RegSecMap1      =       "Map_"
  8634.     RegSecMap2      =       "Map#"
  8635.     RegSecMap3      =       "Map$"
  8636.     RegNTPerfLib    =       "SOFTWARE\Microsoft\Windows NT\CurrentVersion\Perflib"
  8637.     RegSQLWinNT     =       "SOFTWARE\Microsoft\Windows NT\CurrentVersion"
  8638.     RegSQLSvcMgr    =       "SQL Service Manager"
  8639.     RegSQLDBLib     =       "DB-Lib"
  8640.     RegSQLConnectTo =       "ConnectTo"
  8641.     RegSQLPrefServers =     "PrefServers"
  8642.     RegMonitor =            "Monitor"
  8643.     RegClient =             "Client"
  8644.     RegSQLServerVer =       "CurrentVersion"
  8645.     RegValSMSVersion   =    "Version"
  8646.     RegSQLServerSvr =       "MSSQLServer"
  8647.     RegOldSQLServerSvr =    "Server"
  8648.     RegSQLSvrParam  =       "Parameters"
  8649.     RegSQLPerformance =     "Performance"
  8650.     RegSvcStart     =       "Start"
  8651.     RegServerAutoStart  =   "RestartSQLServer"
  8652.     RegSchRestart   =       "RestartSQLServerInterval"
  8653.     RegSchSysLimit  =       "SyshistoryLimitRows"
  8654.     RegSchSysMax  =         "SyshistoryMaxRows"
  8655.     RegSchAutoMail =        "MailAutoStart"
  8656.     RegSchServerHost =      "ServerHost"
  8657.     RegSchCmdExec   =       "CmdExec"
  8658.     RegSchReplSync  =       "Sync"
  8659.     RegSchReplReader =       "LogReader"
  8660.     RegSchReplDist  =       "Distribution"
  8661.     RegSchReplLCDist  =     ""
  8662.     RegValDSQUERY   =       "DSQUERY"
  8663.     RegValServerAutoStart =  "1"
  8664.     RegValBackupTime=       "15"
  8665.     RegValBackupRetry =     "3"
  8666.     RegValTime      =       "60"
  8667.     RegValTableSize =       "1000"
  8668.     RegValMntr      =       "OFF"
  8669.     RegValTimeout   =       "360"
  8670.     RegValServer    =       ""
  8671.     RegValBackup    =       "ON"
  8672.     RegValLogsize   =       "4096"
  8673.     RegValLibrary   =       "Library"
  8674.     RegValPerfSync  =       "Synchronous"
  8675.     RegValOpen      =       "Open"
  8676.     RegValCollect   =       "Collect"
  8677.     RegValClose     =       "Close"
  8678.     RegValFirstCntr =       "FirstCounter"
  8679.     RegValFirstHelp =       "FirstHelp"
  8680.     RegValLastCntr  =       "Last Counter"
  8681.     RegValLastHelp  =       "Last Help"
  8682.     RegValLoginTO   =       "LoginTimeOut"
  8683.     RegValQueryTO   =       "QueryTimeOut"
  8684.     RegValCounters  =       "Counters"
  8685.     RegValHelp      =       "Help"
  8686.     RegValSystemRoot=       "SystemRoot"
  8687.     RegValCurBuild  =       "CurrentBuildNumber"
  8688.     RegValANSIToOEM =       "AutoAnsiToOem"
  8689.     RegValTCPTries  =       "TcpKeepTries"
  8690.     RegValTCPCnt    =       "TcpKeepCnt"
  8691.     RegValUseIntl   =       "UseIntlSettings"
  8692.     RegValReplDir   =       "WorkingDirectory"
  8693.     RegValSchedrestart =    "5"
  8694.     RegValLimitRows =       "1"
  8695.     RegValMaxRows =         "1000"
  8696.     RegValCmdExec   =       "CmdExecStart,CmdEvent,CmdExecStop,10"
  8697.     RegValReplSync  =       "sync_start,sync_event,sync_stop,100"
  8698.     RegValReplReader=       "logreader_start,logreader_event,logreader_stop,25"
  8699.     RegValReplDist  =       "distribution_start,distribution_event,distribution_stop,100"
  8700.     
  8701.     DefPerfLangID   =       "009"
  8702.     SystemMemory    =       "" ? $(!DLLSQL) GetMemorySize
  8703.     MinSystemMemory =       12000
  8704.     MinOSVersion    =       "3.51.1057.0"
  8705.     RdrMinOSVersion =       "3.51.1057.0"
  8706.     LicenseMin      =       "1057"
  8707.     SQLBookB2       =       "SQLBOOKS"
  8708.     SQLBookMVB      =       "SQLBOOKS.MVB"
  8709.     SQLBookSetSec   =       "SQLBOOKS.Settings"
  8710.     SQLBookLDir     =       "LocalDir"
  8711.     SQLBookExe      =       "Exe"
  8712.     SQLBookTitle    =       "title"
  8713.     SQLBookInsType  =       "installtype"
  8714.     SQLBookSInsType =       "Standard"
  8715.     SQLBookCInsType =       "Complete"
  8716.     SQLBookSeries   =       "series"
  8717.     SQLBookAllTitle =       "all titles"
  8718.     SQLBookLisNa    =       "licensed.name"
  8719.     SQLBookLisOr    =       "licensed.organization"
  8720.     SQLBookLisVr    =       "license_version"
  8721.     SQLBookLisLr    =       "license_last_read"
  8722.     SQLBookLisDt    =       "5/21/94"
  8723.     SQLBookIni      =       "INFOVIEW.INI"
  8724.     KeysDupped      =       "FALSE"
  8725.     RemoteKeysDupped =      "FALSE"
  8726.     SQL95Keys       =       "FALSE"
  8727.     NewInstall      =       "FALSE"
  8728.     MultiProtEncrypt =      ""
  8729.     RegRPCNetLib     =      "RPCNetLib"
  8730.     RegValRPCSec     =      "Security"
  8731.     RegValEncrypt    =      "Encrypt"
  8732.     RegValClientImp  =      "ImpersonateClient"
  8733.     ExpMstr          =      "disk resize name = master,size = "
  8734.     MstrSize         =      "25"
  8735.     RdrCopy          =      "TRUE"
  8736.     OldListenOn      =      {$(!NetLibPipes)","$(!SvrPipe)}
  8737.     PerSeatMode      =      0
  8738.     PerSeatNumber    =      50
  8739.     RemoteSystemRoot =      ""
  8740.     LocalRemoteSystemRoot =      ""
  8741.     OldSQLMapi       =      "SQLMAPI,startmail"
  8742.     LicenseSet       =      "FALSE"
  8743.     ClientInstallKey =      "FALSE"
  8744.     RegLicenseSubKey =      "MSSQL6.50"
  8745.     RegLic60SubKey  =       "MSSQL6.00"
  8746.     LicGeneralHelp   =      "152"
  8747.     LicServerHelp    =      "154"
  8748.     LicSeatHelp      =      "153"
  8749.     LicFullSetup     =      "FULLSETUP"
  8750.     LicRemoteFullSetup =    "REMOTEFULLSETUP"
  8751.     LicUnattendedFullSetup = "UNATTENDED"
  8752.     LicenseWritten   =      "FALSE"
  8753.     TraceSQLKeyDB    =      "-T3643"
  8754.     TFlagBypassSSP  =       "-T4022"
  8755.     RegValNullPipes =     "NullSessionPipes"
  8756.     RegValEpmapper  =    "EPMAPPER"
  8757.     RegOldLicenseSubKey =   "SQL"
  8758.     RegValSetupState =      "SetupStatus"
  8759.     RegValSetupCRC     =    "CRC"
  8760.     RegValUpgrading  =      "Upgrade"
  8761.     RegValInstalled  =      "Installed"
  8762.     StandAloneRelease=      "20971545"
  8763.     SQLBooksDir     =       "..\SQLBKS65"
  8764.     SQLUseMaster        = "use master"    
  8765.         SQLReleaseNumber=    "4227071"
  8766. ;*************************************************************************
  8767. ;*************************************************************************
  8768. ;* INTERNATIONALIZABLE CODE
  8769. ;* This file should be appended to setup.src to make setup.inf
  8770. ;*************************************************************************
  8771. ;*************************************************************************
  8772.     UpgMemNT42                = "750"
  8773.     InstScriptsList            = {$(!InstUpg),$(!InstChkObj),$(!InstMsgs),$(!InstSptVal),$(!InstSysCfg),$(!InstProc),$(!InstRepl),$(!InstCat),$(!InstConfig),$(!InstXPStar),$(!InstSch),$(!InstSmsg),$(!InstSQLOle)}
  8774.     UpgScriptsNT42            = {$(!DropAll),$(!UnAdmin),$(!UnObject),$(!InstUpg),$(!InstChkObj),$(!InstMsgs),$(!InstSptVal),$(!InstSysCfg),$(!InstProc),$(!InstRepl),$(!InstEarly),$(!InstCat),$(!InstConfig),$(!InstXPStar),$(!InstSch),$(!InstSmsg),$(InstSQLOle),$(!InstOM),$(!InstAdmin)}
  8775.     DrpBinnFiles            = {"bldmastr.exe","upgrade.exe","sqlmontr.exe","netsql.exe","wtapedir.exe","tapeutil.hlp","ntwdbver.exe"}
  8776.     DrpDLLFiles                = {"opendsnt.dll","ssnmpntw.dll","xpsql.dll","sqlperf.dll","ssmssocn.dll","sqlevent.dll","sqlctrs.dll","evntctrs.dll","xplogin.dll","ssmsspxn.dll","sqlmapi.dll"}
  8777.     DrpInsFiles                = {"instmstr.sql","instmodl.sql","admin2.sql","object2.sql","unobj.sql","instnt.sql","mstrfree.sql","dnnt42.sql","readme.hlp"}
  8778.     ANSItoOEMDef            = "ON"
  8779.     Setup_Title                = "Microsoft SQL Server 6.5"
  8780.     LicenseFamilyName        = "Microsoft SQL Server"
  8781.     SQLProgmanGrpName        = "Microsoft SQL Server 6.5"
  8782.     SQL60ProgmanGrpName     = "Microsoft SQL Server 6.0"
  8783.     SQLBetaProgmanGrpName    = "Microsoft SQL Server 6.0 Beta"
  8784.     SQLUtilsGrpName            = "Microsoft SQL Server 6.5 Utilities"
  8785.     OldSQLProgmanGrpName    = "SQL Server for Windows NT"
  8786.     SQLBooksFullTitle        = "SQL Server Books Online"
  8787.     DefSQLDLGPath            = "SQL Server Path"
  8788.     SQLPubs                    = "select name from master.dbo.sysdatabases where name like 'pubs'"
  8789.     Pubs                    = "pubs"
  8790.     PleaseWait                = "You may continue with another task..."
  8791.  
  8792.     MasterDBSize            = " + master size"
  8793.  
  8794.     CharSetSelList            = {    "ISO Character Set (Default)","cpISO", +
  8795.                                 "850 Multilingual","cp850", +
  8796.                                 "437 US English","cp437", +
  8797.                                 "932 Japanese","cp932", +
  8798.                                 "936 Chinese (simplified)","cp936", +
  8799.                                 "949 Korean","cp949", +
  8800.                                 "950 Chinese (traditional)","cp950", +
  8801.                                 "1250 Central European","cp1250", +
  8802.                                 "1251 Cyrillic","cp1251", +
  8803.                                 "1253 Greek","cp1253", +
  8804.                                 "1254 Turkish","cp1254", +
  8805.                                 "1255 Hebrew","cp1255", +
  8806.                                 "1256 Arabic","cp1256", +
  8807.                                 "1257 Baltic","cp1257"}
  8808.  
  8809.     CharSetUserSelList        = {    "ISO Character Set (Default)","cpISO", +
  8810.                                 "850 Multilingual","cp850", +
  8811.                                 "437 US English","cp437", +
  8812.                                 "932 Japanese","cp932", +
  8813.                                 "936 Chinese (simplified)","cp936", +
  8814.                                 "949 Korean","cp949", +
  8815.                                 "950 Chinese (traditional)","cp950", +
  8816.                                 "1250 Central European","cp1250", +
  8817.                                 "1251 Cyrillic","cp1251", +
  8818.                                 "1253 Greek","cp1253", +
  8819.                                 "1254 Turkish","cp1254", +
  8820.                                 "1255 Hebrew","cp1255", +
  8821.                                 "1256 Arabic","cp1256", +
  8822.                                 "1257 Baltic","cp1257"}
  8823.  
  8824.     TCPIPName = "TCP/IP Sockets"
  8825.  
  8826.     ValidNetLibs        = {$(!NetLibPipes),$(!NetLibRPC),$(!NetLibSPX),$(!NetLibTCPIP),$(!NetLibADSP),$(!NetLibVines),$(!NetLibDECNet),$(!UserDefined),$(!UserProvided)}
  8827.     DefNetworkSelList    = {    "Named Pipes",$(!NetLibPipes),"0","Multi-Protocol",$(!NetLibRPC),"1",+
  8828.                             "NWLink IPX/SPX",$(!NetLibSPX),"2",$(!TCPIPName),$(!NetLibTCPIP),"3",+
  8829.                             "Apple Talk ADSP",$(!NetLibADSP),"4","Banyan VINES",$(!NetLibVines),"5",+
  8830.                             "DEC Net Sockets",$(!NetLibDECNet),"6"}
  8831.  
  8832.     DefNetworkRISCSelList = {    "Named Pipes",$(!NetLibPipes),"0","Multi-Protocol",$(!NetLibRPC),"1",+
  8833.                                 "NWLink IPX/SPX",$(!NetLibSPX),"2",$(!TCPIPName),$(!NetLibTCPIP),"3",+
  8834.                                 "Apple Talk ADSP",$(!NetLibADSP),"4","DEC Net Sockets",$(!NetLibDECNet),"5"}
  8835.  
  8836.     DefSecNetworkSelList = {"Named Pipes",$(!NetLibPipes),"0","Multi-Protocol",$(!NetLibRPC),"1" }
  8837.  
  8838.     SecStrNotUsed        = "(not used)"
  8839.     SecStrDomSep        = "(domain separator '\')"
  8840.     SecStrSpace            = "(space)"
  8841.     DefSecurityTokens    = {    $(!SecStrNotUsed),$(!SecStrDomSep),$(!SecStrSpace),"-",".","'",+
  8842.                             "!","@","%","^","&"}
  8843.  
  8844.     UpgErrorMastSpace    = "There is insufficient space in the master database"$(!LF)
  8845.     UpgErrorROs            = "Read Only databases are present"$(!LF)
  8846.     UpgErrorSuspect        = "There are suspect databases"$(!LF)
  8847.     UpgErrorNumDBs        = "There are too many databases"$(!LF)
  8848.  
  8849.     DefUserProvNet        = {"User provided",$(!UserDefined),"3"}
  8850. ;    NetworkDefList        = {"Named Pipes",$(NetLibPipes),"0"}
  8851.     DefSortFileIndex    = 1
  8852.     Sort850SelList        = {    "Dictionary order, case-insensitive","nocase.850","42",+
  8853.                             "Binary order","cp850bin.850","40", +
  8854.                             "Dictionary order, case-sensitive","diction.850","41",  +
  8855.                             "Dictionary order, case-insensitive, uppercase preference","nocasepr.850","43", +
  8856.                             "Dictionary order, case-insensitive, accent-insensitive","noaccent.850","44", +
  8857.                             "Strict compatibility with Version 1.x case-insensitive databases","nocase34.850","49", +
  8858.                             "Alternate dictionary order, case-sensitive","altdict.850","55",+
  8859.                             "Alternate dictionary order, case-insensitive","altnocs.850","61",+
  8860.                             "Alternate dictionary order, case-insensitive, uppercase preference","altnocsp.850","56",+
  8861.                             "Alternate dictionary order, case-insensitive, accent-insensitive","altnoacc.850","57",+
  8862.                             "Scandinavian dictionary order, case-sensitive","scandict.850","59",+
  8863.                             "Scandinavian dictionary order, case-insensitive, uppercase preference","scannocp.850","58",+
  8864.                             "Custom",$(!UserDefined),""}
  8865.     Sort437SelList        = {    "Dictionary order, case-insensitive","nocase.437","32", +
  8866.                             "Binary order","cp437bin.437","30", +
  8867.                             "Dictionary order, case-sensitive","diction.437","31", +
  8868.                             "Dictionary order, case-insensitive, uppercase preference","nocasepr.437","33", +
  8869.                             "Dictionary order, case-insensitive, accent-insensitive","noaccent.437","34",+
  8870.                             "Custom",$(!UserDefined),""}
  8871.     SortISOSelList        = {    "Dictionary order, case-insensitive","nocase.iso","52",+
  8872.                             "Binary order","iso_1bin.iso","50", +
  8873.                             "Dictionary order, case-sensitive","diction.iso","51", +
  8874.                             "Dictionary order, case-insensitive, uppercase preference","nocasepr.iso","53", +
  8875.                             "Dictionary order, case-insensitive, accent-insensitive","noaccent.iso","54",+
  8876.                             "Dictionary order, case-insensitive, uppercase pref. for Danish/Norwegian","danonocp.iso","183",+
  8877.                             "Dictionary order, case-insensitive, uppercase pref. for Icelandic","islanocp.iso","186",+
  8878.                             "Dictionary order, case-insensitive, uppercase pref. for Swedish/Finnish (Std)","svf2nocp.iso","185",+
  8879.                             "Dictionary order, case-insensitive, uppercase pref. for Swedish/Finnish (Phone)","svf1nocp.iso","184",+
  8880.                             "Custom",$(!UserDefined),""}
  8881.     Sort1250SelList        = {    "Dictionary order, case-insensitive","nocase.250","82", +
  8882.                             "Binary order","binary.250","80", +
  8883.                             "Dictionary order, case-sensitive","diction.250","81", +
  8884.                             "Czech dictionary order, case-sensitive", "csydic.250", "83", +
  8885.                             "Czech dictionary order, case-insensitive", "csync.250", "84" +
  8886.                             "Hungarian dictionary order, case-sensitive", "hundic.250", "85", +
  8887.                             "Hungarian dictionary order, case-insensitive", "hunnc.250", "86", +
  8888.                             "Polish dictionary order, case-sensitive", "plkdic.250", "87", +
  8889.                             "Polish dictionary order, case-insensitive", "plknc.250", "88", +
  8890.                             "Romanian dictionary order, case-sensitive", "romdic.250", "89", +
  8891.                             "Romanian dictionary order, case-insensitive", "romnc.250", "90", +
  8892.                             "Croatian dictionary order, case-sensitive", "shldic.250", "91", +
  8893.                             "Croatian dictionary order, case-insensitive", "shlnc.250", "92", +
  8894.                             "Slovak dictionary order, case-sensitive", "skydic.250", "93", +
  8895.                             "Slovak dictionary order, case-insensitive", "skync.250", "94", +
  8896.                             "Slovenian dictionary order, case-sensitive", "slvdic.250", "95", +
  8897.                             "Slovenian dictionary order, case-insensitive", "slvnc.250", "96", +
  8898.                             "Custom",$(!UserDefined),""}
  8899.     Sort1251SelList        = {    "Dictionary order, case-insensitive","nocase.251","106", +
  8900.                             "Binary order","binary.251","104", +
  8901.                             "Dictionary order, case-sensitive","diction.251","105", +
  8902.                             "Ukrainian dictionary order, case-sensitive", "ukrdic.251", "107", +
  8903.                             "Ukrainian dictionary order, case-insensitive", "ukrnc.251", "108", +
  8904.                             "Custom",$(!UserDefined),""}
  8905.     Sort1253SelList        = {    "Dictionary order, case-insensitive","nocase.253","114", +
  8906.                             "Binary order","binary.253","112", +
  8907.                             "Dictionary order, case-sensitive","diction.253","113", +
  8908.                             "Mixed Dictionary order", "grmxtdct.253", "120", +
  8909.                             "Dictionary order, case-sensitive, accent-sensitive", "graltdct.253", "121", +
  8910.                             "Dictionary order, case-insensitive, accent-insensitive", "grnoacce.253", "124", +
  8911.                             "Custom",$(!UserDefined),""}
  8912.     Sort1254SelList        = {    "Dictionary order, case-insensitive","nocase.254","130", +
  8913.                             "Binary order","binary.254","128", +
  8914.                             "Dictionary order, case-sensitive","diction.254","129", +
  8915.                             "Custom",$(!UserDefined),""}
  8916.     Sort1255SelList        = {    "Dictionary order, case-insensitive","nocase.255","138", +
  8917.                             "Binary order","binary.255","136", +
  8918.                             "Dictionary order, case-sensitive","diction.255","137", +
  8919.                             "Custom",$(!UserDefined),""}
  8920.     Sort1256SelList        = {    "Dictionary order, case-insensitive","nocase.256","146", +
  8921.                             "Binary order","binary.256","144", +
  8922.                             "Dictionary order, case-sensitive","diction.256","145", +
  8923.                             "Custom",$(!UserDefined),""}
  8924.     Sort1257SelList        = {    "Dictionary order, case-insensitive","nocase.257","154", +
  8925.                             "Binary order","binary.257","152", +
  8926.                             "Dictionary order, case-sensitive","nocase.257","153", +
  8927.                             "Estonian dictionary order, case-sensitive", "etidic.257", "155", +
  8928.                             "Estonian dictionary order, case-insensitive", "etinc.257", "156", +
  8929.                             "Latvian dictionary order, case-sensitive", "lvidic.257", "157", +
  8930.                             "Latvian dictionary order, case-insensitive", "lvinc.257", "158", +
  8931.                             "Lithuanian dictionary order, case-sensitive", "lthdic.257", "159", +
  8932.                             "Lithuanian dictionary order, case-sensitive", "lthdic.257", "160", +
  8933.                             "Custom",$(!UserDefined),""}
  8934.     Sort932SelList        = {    "Dictionary order, case-insensitive (NT-provided)","cp932nls.932","193", +
  8935.                             "Binary order","cp932bin.932","50", +
  8936.                             "Custom",$(!UserDefined),""}
  8937.     Sort936SelList        = {    "Dictionary order, case-insensitive (NT-provided)","cp936nls.936","199", +
  8938.                             "Binary order","cp936bin.936","198", +
  8939.                             "Custom",$(!UserDefined),""}
  8940.     Sort949SelList        = {    "Dictionary order, case-insensitive (NT-provided)","cp949nls.949","195", +
  8941.                             "Binary order","cp949bin.949","194", +
  8942.                             "Custom",$(!UserDefined),""}
  8943.     Sort950SelList        = {    "Dictionary order, case-insensitive (NT-provided)","cp950nls.950","197", +
  8944.                             "Binary order","cp950bin.950","196", +
  8945.                             "Custom",$(!UserDefined),""}
  8946.  
  8947. [RemoveOldSQLGroup]
  8948.     set SQLGroup = $(!OldSQLProgmanGrpName)
  8949.     RemoveProgmanItem $(SQLGroup),"SQL Setup","COMMON"
  8950.     RemoveProgmanItem $(SQLGroup),"SQL Service Manager","COMMON"
  8951.     RemoveProgmanItem $(SQLGroup),"ISQL/w","COMMON"
  8952.     RemoveProgmanItem $(SQLGroup),"SQL Tape Utility","COMMON"
  8953.     RemoveProgmanItem $(SQLGroup),"SQL Client Configuration Utility","COMMON"
  8954.     RemoveProgmanItem $(SQLGroup),"SQL Security Manager","COMMON"
  8955.     RemoveProgmanItem $(SQLGroup),"SQL Transfer Manager","COMMON"
  8956.     RemoveProgmanItem $(SQLGroup),"SQL Administrator Win32","COMMON"
  8957.     RemoveProgmanItem $(SQLGroup),"SQL Object Manager Win32","COMMON"
  8958.     RemoveProgmanItem $(SQLGroup),"SQL Performance","COMMON"
  8959.     RemoveProgmanItem $(SQLGroup),"SQL Help","COMMON"
  8960.     RemoveProgmanItem $(SQLGroup),"Release Notes","COMMON"
  8961.     RemoveProgManGroup $(SQLGroup),"COMMON"
  8962.     exit
  8963.  
  8964. [CreateSQLProgmanItems]
  8965.     set SQLGroup = $(!SQLProgmanGrpName)
  8966.     ifstr(i) $(!STF_OS) == "95"
  8967.         set Isqlw2 = "ISQL_w"
  8968.     else
  8969.         set Isqlw2 = "ISQL/w"
  8970.     endif
  8971.     CreateProgManGroup $(SQLGroup),"","COMMON"
  8972.  
  8973.     RemoveProgmanItem $(SQLGroup),"SQL Setup","COMMON"
  8974.     RemoveProgmanItem $(SQLGroup),"SQL Service Manager","COMMON"
  8975.     RemoveProgmanItem $(SQLGroup),"ISQL/w 2.0","COMMON"
  8976.     RemoveProgmanItem $(SQLGroup),$(Isqlw2),"COMMON"
  8977.     RemoveProgmanItem $(SQLGroup),"SQL Tape Utility","COMMON"
  8978.     RemoveProgmanItem $(SQLGroup),"SQL Client Configuration Utility","COMMON"
  8979.     RemoveProgmanItem $(SQLGroup),"SQL Security Manager","COMMON"
  8980.     RemoveProgmanItem $(SQLGroup),"SQL Transfer Manager","COMMON"
  8981.     RemoveProgmanItem $(SQLGroup),"SQL Enterprise Manager","COMMON"
  8982.     ifstr(i) $(!InstallType) != "2"
  8983.         RemoveProgmanItem $(SQLGroup),"SQL Administrator Win32","COMMON"
  8984.         RemoveProgmanItem $(SQLGroup),"SQL Object Manager Win32","COMMON"
  8985.     endif
  8986.     RemoveProgmanItem $(SQLGroup),"SQL Performance Monitor","COMMON"
  8987.     RemoveProgmanItem $(SQLGroup),"SQL Performance","COMMON"
  8988.     RemoveProgmanItem $(SQLGroup),"SQL Books Online","COMMON"
  8989.     RemoveProgmanItem $(SQLGroup),"SQL Distributed Management Objects","COMMON"
  8990.     RemoveProgmanItem $(SQLGroup),$(!SQLBooksFullTitle),"COMMON"
  8991.     RemoveProgmanItem $(SQLGroup),"SQL Help","COMMON"
  8992.     RemoveProgmanItem $(SQLGroup),"Microsoft ODBC SQL Server Driver","COMMON"
  8993.     RemoveProgmanItem $(SQLGroup),"Release Notes","COMMON"
  8994.     RemoveProgmanItem $(SQLGroup),"Readme.txt","COMMON"
  8995.     RemoveProgmanItem  $(SQLGroup),"MSDTC Administrative Console","COMMON"
  8996.     RemoveProgmanItem  $(SQLGroup),"Client","COMMON"
  8997.     RemoveProgmanItem  $(SQLGroup),"MS Query","COMMON"
  8998.  
  8999.     CreateProgmanItem  $(SQLGroup),"SQL Enterprise Manager",$(!SQLPath)"\"$(!Binaries)"\"$(!SQLStarfterEXE),$(!SQLPath)"\"$(!Binaries)"\"$(!SQLStarfterEXE),0,"COMMON"
  9000.     CreateProgmanItem  $(SQLGroup),"SQL Service Manager",$(!SQLPath)"\"$(!Binaries)"\"$(!StopLite),$(!SQLPath)"\"$(!Binaries)"\"$(!StopLite),0,"COMMON"
  9001.     CreateProgmanItem  $(SQLGroup),$(Isqlw2),$(!SQLPath)"\"$(!Binaries)"\"$(!ISQLWEXE),$(!SQLPath)"\"$(!Binaries)"\"$(!ISQLWEXE),0,"COMMON"
  9002.     CreateProgmanItem  $(SQLGroup),"SQL Security Manager",$(!SQLPath)"\"$(!Binaries)"\"$(!SQLSecManEXE),$(!SQLPath)"\"$(!Binaries)"\"$(!SQLSecManEXE),0,"COMMON"
  9003.     CreateProgmanItem  $(SQLGroup),"SQL Trace",$(!SQLPath)"\"$(!Binaries)"\"$(!SQLTraceEXE),$(!SQLPath)"\"$(!Binaries)"\"$(!SQLTraceEXE),0,"COMMON"
  9004.     CreateProgmanItem  $(SQLGroup),"SQL Client Configuration Utility",$(!SQLPath)"\"$(!Binaries)"\"$(!SQLClientEXE),$(!SQLPath)"\"$(!Binaries)"\"$(!SQLClientEXE),0,"COMMON"
  9005.     CreateProgmanItem  $(SQLGroup),"SQL Performance Monitor",$(!PerfMonEXE)" "$(!SQLPath)"\"$(!Binaries)"\"$(!SQLCtrsPMC),$(!PerfMonEXE),0,"COMMON"
  9006.     ifstr(i) $(!RISCInst) != "YES"
  9007.         CreateProgmanItem  $(SQLGroup),"MS Query",$(!SystemDirectory)"\..\"$(!MSQueryDir)"\"$(!MSQueryEXE),$(!SystemDirectory)"\..\"$(!MSQueryDir)"\"$(!MSQueryEXE),0,"COMMON"
  9008.         CreateProgmanItem  $(SQLGroup),"SQL Web Page Wizard",$(!SQLPath)"\"$(!Binaries)"\"$(!WebWizardEXE),$(!SQLPath)"\"$(!Binaries)"\"$(!WebWizardEXE),0,"COMMON"
  9009.     endif
  9010.     ifstr(i) $(!SQLBooksType) == "1"
  9011.         CreateProgmanItem  $(SQLGroup),$(!SQLBooksFullTitle), $(!SQLPath)"\"$(!Binaries)"\INFOVIEW.EXE "$(!SQLBookMVB),$(!SQLPath)"\"$(!InstallDir)"\SQLBOOKS.ICO",0,"COMMON"
  9012.     else-ifstr(i) $(!SQLBooksType) == "2"
  9013.         CreateProgmanItem  $(SQLGroup),$(!SQLBooksFullTitle), $(!SQLPath)"\"$(!Binaries)"\INFOVIEW.EXE "$(!SQLBookMVB),$(!SQLPath)"\"$(!InstallDir)"\SQLBOOKS.ICO",0,"COMMON"
  9014.     endif
  9015.     CreateProgmanItem  $(SQLGroup),"Microsoft ODBC SQL Server Driver",$(!STF_WINDOWSSYSPATH)"\"$(!WinHelpEXE)" "$(!STF_WINDOWSSYSPATH)"\"$(!HelpODBCInst),$(!STF_WINDOWSSYSPATH)"\"$(!WinHelpEXE),0,"COMMON"
  9016.     CreateProgmanItem  $(SQLGroup),"SQL Distributed Management Objects",$(!STF_WINDOWSSYSPATH)"\"$(!WinHelpEXE)" "$(!SQLPath)"\"$(!DLLs)"\"$(!SQLOleHlp),$(!STF_WINDOWSSYSPATH)"\"$(!WinHelpEXE),0,"COMMON"
  9017.     CreateProgmanItem  $(SQLGroup),"Readme.txt",$(!STF_WINDOWSSYSPATH)"\"$(!NotePadEXE)" "$(!SQLPath)"\"$(!InstallDir)"\readme.txt",$(!STF_WINDOWSSYSPATH)"\"$(!NotePadEXE),0,"COMMON"
  9018.     CreateProgmanItem  $(SQLGroup),"SQL Setup",$(!SQLPath)"\"$(!Binaries)"\"$(!SetupEXE),$(!SQLPath)"\"$(!Binaries)"\"$(!SetupEXE),0,"COMMON"
  9019.  
  9020.     exit
  9021.  
  9022. [NukeSQLProgmanItems]
  9023.     set SQLGroup = $(!ProgramTitle)
  9024.     ifstr(i) $(!STF_OS) == "95"
  9025.         set Isqlw2 = "ISQL_w"
  9026.     else
  9027.         set Isqlw2 = "ISQL/w"
  9028.     endif
  9029.     RemoveProgmanItem $(SQLGroup),"SQL Setup","COMMON"
  9030.     RemoveProgmanItem $(SQLGroup),"SQL Service Manager","COMMON"
  9031.     RemoveProgmanItem $(SQLGroup),"ISQL/w 2.0","COMMON"
  9032.     RemoveProgmanItem $(SQLGroup),"ISQL_w","COMMON"
  9033.     RemoveProgmanItem $(SQLGroup),"ISQL/w","COMMON"
  9034.     RemoveProgmanItem $(SQLGroup),"SQL Tape Utility","COMMON"
  9035.     RemoveProgmanItem $(SQLGroup),"SQL Security Manager","COMMON"
  9036.     RemoveProgmanItem $(SQLGroup),"SQL Client Configuration Utility","COMMON"
  9037.     RemoveProgmanItem $(SQLGroup),"SQL Transfer Manager","COMMON"
  9038.     RemoveProgmanItem $(SQLGroup),"SQL Administrator Win32","COMMON"
  9039.     RemoveProgmanItem $(SQLGroup),"SQL Object Manager Win32","COMMON"
  9040.     RemoveProgmanItem $(SQLGroup),"SQL Enterprise Manager","COMMON"
  9041.     RemoveProgmanItem $(SQLGroup),"SQL Performance Monitor","COMMON"
  9042.     RemoveProgmanItem $(SQLGroup),"SQL Web Page Wizard","COMMON"
  9043.     RemoveProgmanItem $(SQLGroup),"SQL Trace","COMMON"
  9044.     RemoveProgmanItem $(SQLGroup),"SQL Performance","COMMON"
  9045.     RemoveProgmanItem $(SQLGroup),"SQL Books Online","COMMON"
  9046.     RemoveProgmanItem $(SQLGroup),"SQL Distributed Management Objects","COMMON"
  9047.     RemoveProgmanItem $(SQLGroup),$(!SQLBooksFullTitle),"COMMON"
  9048.     RemoveProgmanItem $(SQLGroup),"Microsoft ODBC SQL Server Driver","COMMON"
  9049.     RemoveProgmanItem $(SQLGroup),"Readme.txt","COMMON"
  9050.     RemoveProgmanItem  $(SQLGroup),"MS Query","COMMON"
  9051.     RemoveProgManItem $(SQLGroup), "DB-Library Help", "COMMON"
  9052.     RemoveProgManGroup $(SQLGroup),"COMMON"
  9053.     exit
  9054.  
  9055. [NukeSQL60ProgmanItems]
  9056.     set SQLGroup = $(!SQL60ProgramTitle)
  9057.     ifstr(i) $(!STF_OS) == "95"
  9058.         set Isqlw2 = "ISQL_w"
  9059.     else
  9060.         set Isqlw2 = "ISQL/w"
  9061.     endif
  9062.     RemoveProgmanItem $(SQLGroup),"SQL Setup","COMMON"
  9063.     RemoveProgmanItem $(SQLGroup),"SQL Service Manager","COMMON"
  9064.     RemoveProgmanItem $(SQLGroup),"ISQL/w 2.0","COMMON"
  9065.     RemoveProgmanItem $(SQLGroup),$(Isqlw2),"COMMON"
  9066.     RemoveProgmanItem $(SQLGroup),"SQL Tape Utility","COMMON"
  9067.     RemoveProgmanItem $(SQLGroup),"SQL Security Manager","COMMON"
  9068.     RemoveProgmanItem $(SQLGroup),"SQL Client Configuration Utility","COMMON"
  9069.     RemoveProgmanItem $(SQLGroup),"SQL Transfer Manager","COMMON"
  9070.     RemoveProgmanItem $(SQLGroup),"SQL Administrator Win32","COMMON"
  9071.     RemoveProgmanItem $(SQLGroup),"SQL Object Manager Win32","COMMON"
  9072.     RemoveProgmanItem $(SQLGroup),"SQL Enterprise Manager","COMMON"
  9073.     RemoveProgmanItem $(SQLGroup),"SQL Performance Monitor","COMMON"
  9074.     RemoveProgmanItem $(SQLGroup),"SQL Performance","COMMON"
  9075.     RemoveProgmanItem $(SQLGroup),"SQL Books Online","COMMON"
  9076.     RemoveProgmanItem $(SQLGroup),"SQL Distributed Management Objects","COMMON"
  9077.     RemoveProgmanItem $(SQLGroup),$(!SQLBooksFullTitle),"COMMON"
  9078.     RemoveProgmanItem $(SQLGroup),"Microsoft ODBC SQL Server Driver","COMMON"
  9079.     RemoveProgmanItem $(SQLGroup),"Readme.txt","COMMON"
  9080.     RemoveProgManItem $(SQLGroup), "DB-Library Help", "COMMON"
  9081.     RemoveProgManGroup $(SQLGroup),"COMMON"
  9082.     exit
  9083.  
  9084. [CreateUtilProgmanItems]
  9085.     ifstr(i) $(!UserType) == "Admin"
  9086.         set SQLGroup = $(!SQLProgmanGrpName)
  9087.         set ProgmanType = "COMMON"
  9088.     else
  9089.         set SQLGroup = $(!SQLUtilsGrpName)
  9090.         set ProgmanType = "VITAL"
  9091.     endif
  9092.     ifstr(i) $(!STF_OS) == "95"
  9093.         set Isqlw2 = "ISQL_w"
  9094.     else
  9095.         set Isqlw2 = "ISQL/w"
  9096.     endif
  9097.     CreateProgManGroup $(SQLGroup),"",$(ProgmanType)
  9098.     RemoveProgmanItem $(SQLGroup),"SQL Administrator Win32",$(ProgmanType)
  9099.     CreateProgManGroup $(SQLGroup),"",$(ProgmanType)
  9100.     RemoveProgmanItem $(SQLGroup),"SQL Object Manager Win32",$(ProgmanType)
  9101.     ifcontains(i) $(!SQLStarfterEXE) in $(!UtilFiles)
  9102.         CreateProgManGroup $(SQLGroup),"",$(ProgmanType)
  9103.         RemoveProgmanItem $(SQLGroup),"SQL Enterprise Manager",$(ProgmanType)
  9104.         CreateProgmanItem  $(SQLGroup),"SQL Enterprise Manager",$(!SQLPath)"\"$(!Binaries)"\"$(!SQLStarfterEXE),$(!SQLPath)"\"$(!Binaries)"\"$(!SQLStarfterEXE),0,$(ProgmanType)
  9105.     endif
  9106.     ifcontains(i) $(!ISQL) in $(!UtilFiles)
  9107.         CreateProgManGroup $(SQLGroup),"",$(ProgmanType)
  9108.         RemoveProgmanItem $(SQLGroup),$(Isqlw2),$(ProgmanType)
  9109.         RemoveProgmanItem $(SQLGroup),"ISQL/w 2.0",$(ProgmanType)
  9110.         CreateProgmanItem  $(SQLGroup),$(Isqlw2),$(!SQLPath)"\"$(!Binaries)"\"$(!ISQLWEXE),$(!SQLPath)"\"$(!Binaries)"\"$(!ISQLWEXE),0,$(ProgmanType)
  9111.     endif
  9112.     ifcontains(i) $(!SQLSecManEXE) in $(!UtilFiles)
  9113.         CreateProgManGroup $(SQLGroup),"",$(ProgmanType)
  9114.         RemoveProgmanItem $(SQLGroup),"SQL Security Manager",$(ProgmanType)
  9115.         CreateProgmanItem  $(SQLGroup),"SQL Security Manager",$(!SQLPath)"\"$(!Binaries)"\"$(!SQLSecManEXE),$(!SQLPath)"\"$(!Binaries)"\"$(!SQLSecManEXE),0,$(ProgmanType)
  9116.     endif
  9117.     ifcontains(i) $(!MSQueryEXE) in $(!UtilFiles)
  9118.         CreateProgManGroup $(SQLGroup),"",$(ProgmanType)
  9119.         RemoveProgmanItem  $(SQLGroup),"MS Query",$(ProgmanType)
  9120.         CreateProgmanItem  $(SQLGroup),"MS Query",$(!SystemDirectory)"\..\"$(!MSQueryDir)"\"$(!MSQueryEXE),$(!SystemDirectory)"\..\"$(!MSQueryDir)"\"$(!MSQueryEXE),0,$(ProgmanType)
  9121.     endif
  9122.     ifcontains(i) $(!WebWizardEXE) in $(!UtilFiles)
  9123.         CreateProgManGroup $(SQLGroup),"",$(ProgmanType)
  9124.         RemoveProgmanItem  $(SQLGroup),"SQL Web Page Wizard",$(ProgmanType)
  9125.         CreateProgmanItem  $(SQLGroup),"SQL Web Page Wizard",$(!SQLPath)"\"$(!Binaries)"\"$(!WebWizardEXE),$(!SQLPath)"\"$(!Binaries)"\"$(!WebWizardEXE),0,$(ProgmanType)
  9126.     endif
  9127.     ifcontains(i) $(!SQLTraceEXE) in $(!UtilFiles)
  9128.         CreateProgManGroup $(SQLGroup),"",$(ProgmanType)
  9129.         RemoveProgmanItem  $(SQLGroup),"SQL Trace",$(ProgmanType)
  9130.         CreateProgmanItem  $(SQLGroup),"SQL Trace",$(!SQLPath)"\"$(!Binaries)"\"$(!SQLTraceEXE),$(!SQLPath)"\"$(!Binaries)"\"$(!SQLTraceEXE),0,$(ProgmanType)
  9131.     endif
  9132.     CreateProgManGroup $(SQLGroup),"",$(ProgmanType)
  9133.     RemoveProgmanItem $(SQLGroup),"SQL Client Configuration Utility",$(ProgmanType)
  9134.     CreateProgmanItem  $(SQLGroup),"SQL Client Configuration Utility",$(!SQLPath)"\"$(!Binaries)"\"$(!SQLClientEXE),$(!SQLPath)"\"$(!Binaries)"\"$(!SQLClientEXE),0,$(ProgmanType)
  9135.     ifstr(i) $(!SQLBooksType) == "1"
  9136.         CreateProgManGroup $(SQLGroup),"",$(ProgmanType)
  9137.         RemoveProgmanItem $(SQLGroup),$(!SQLBooksFullTitle),$(ProgmanType)
  9138.         CreateProgmanItem  $(SQLGroup),$(!SQLBooksFullTitle), $(!SQLPath)"\"$(!Binaries)"\INFOVIEW.EXE "$(!SQLBookMVB),$(!SQLPath)"\"$(!InstallDir)"\SQLBOOKS.ICO",0,$(ProgmanType)
  9139.     else-ifstr(i) $(!SQLBooksType) == "2"
  9140.         CreateProgManGroup $(SQLGroup),"",$(ProgmanType)
  9141.         RemoveProgmanItem $(SQLGroup),$(!SQLBooksFullTitle),$(ProgmanType)
  9142.         CreateProgmanItem  $(SQLGroup),$(!SQLBooksFullTitle), $(!SQLPath)"\"$(!Binaries)"\INFOVIEW.EXE "$(!SQLBookMVB),$(!SQLPath)"\"$(!InstallDir)"\SQLBOOKS.ICO",0,$(ProgmanType)
  9143.     endif
  9144.     CreateProgManGroup $(SQLGroup),"",$(ProgmanType)
  9145.     RemoveProgmanItem $(SQLGroup),"SQL Help",$(ProgmanType)
  9146.     ifstr(i) $(!STF_OS) == "NT"
  9147.         CreateProgmanItem  $(SQLGroup),"SQL Help",$(!STF_WINDOWSSYSPATH)"\"$(!WinHelpEXE)" "$(!SQLPath)"\"$(!Binaries)"\"$(!HelpSQLHLP),$(!STF_WINDOWSSYSPATH)"\"$(!WinHelpEXE),0,$(ProgmanType)
  9148.     else
  9149.         CreateProgmanItem  $(SQLGroup),"SQL Help",$(!STF_WINDOWSPATH)"\"$(!Win95HelpEXE)" "$(!SQLPath)"\"$(!Binaries)"\"$(!HelpSQLHLP),$(!STF_WINDOWSPATH)"\"$(!Win95HelpEXE),0,$(ProgmanType)
  9150.     endif
  9151.     exit
  9152.  
  9153. [NukeClientProgmanItems]
  9154.     ifstr(i) $(!UserType) == "Admin"
  9155.         set SQLGroup = $(!SQLProgmanGrpName)
  9156.         set ProgmanType = "COMMON"
  9157.     else
  9158.         set SQLGroup = $(!SQLUtilsGrpName)
  9159.         set ProgmanType = "VITAL"
  9160.     endif
  9161.     ifstr(i) $(!STF_OS) == "95"
  9162.         set Isqlw2 = "ISQL_w"
  9163.     else
  9164.         set Isqlw2 = "ISQL/w"
  9165.     endif
  9166.     CreateProgManGroup $(SQLGroup),"",$(ProgmanType)
  9167.     RemoveProgmanItem $(SQLGroup),"SQL Administrator Win32",$(ProgmanType)
  9168.     RemoveProgmanItem $(SQLGroup),"SQL Object Manager Win32",$(ProgmanType)
  9169.     RemoveProgmanItem $(SQLGroup),"SQL Enterprise Manager",$(ProgmanType)
  9170.     RemoveProgmanItem $(SQLGroup),$(Isqlw2),$(ProgmanType)
  9171.     RemoveProgmanItem $(SQLGroup),"ISQL/w 2.0",$(ProgmanType)
  9172.     RemoveProgmanItem $(SQLGroup),"SQL Security Manager",$(ProgmanType)
  9173. ;    RemoveProgmanItem $(SQLGroup),"SQL Web Page Wizard",$(ProgmanType)
  9174. ;    RemoveProgmanItem $(SQLGroup),"SQL Trace",$(ProgmanType)
  9175.     RemoveProgmanItem $(SQLGroup),"SQL Client Configuration Utility",$(ProgmanType)
  9176.     RemoveProgmanItem $(SQLGroup),$(!SQLBooksFullTitle),$(ProgmanType)
  9177.     RemoveProgmanItem $(SQLGroup),"SQL Help",$(ProgmanType)
  9178.     RemoveProgManGroup $(SQLGroup),$(ProgmanType)
  9179.     exit
  9180.  
  9181. [Source Media Descriptions]
  9182.     1  = "Microsoft SQL Server for Windows NT Diskette #1"
  9183.  
  9184. [QueryFullNameOrgNameDlgENG]
  9185.     DlgTemplate        =    "DLG_QUERY_FULLNAME_ORGNAME"
  9186.     !SQLDlgNames    = {    "@Caption","Enter Name and Organization", +
  9187.                         "@HELPFILE",$(!HelpSQLNTSetup),+
  9188.                         "@HELPID","144",+
  9189.                         "@DlgText","Please enter your full name in the Name box below.  "+
  9190.                         "If SQL Server will be used for business purposes, enter the name of your company "+
  9191.                         "or organization in the Company box."$(!LF)$(!LF)+
  9192.                         "In the Product ID box enter the ID for this copy of SQL Server.  The Product "+
  9193.                         "ID is provided on the SQL Server CD box."$(LF)$(LF),+
  9194.                         "@Edit1Label","&Name:",+
  9195.                         "@Edit2Label","&Company:",+
  9196.                         "@Edit3Label","&Product ID:",+
  9197.                         "@Continue","C&ontinue",+
  9198.                         "@Exit","E&xit",+
  9199.                         "@Help","&Help",+
  9200.                         "@EDITIN1",$(!FullName),+
  9201.                         "@EDITIN2",$(!OrgName),+
  9202.                         "@EDITIN3",$(!ProductID),+
  9203.                         "@EDITLEN1","100",+
  9204.                         "@EDITLEN2","100",+
  9205.                         "@EDITLEN3","100"}
  9206.  
  9207. [VerifyFullNameOrgNameDlgENG]
  9208.     DlgTemplate        =    "DLG_VERIFY_FULLNAME_ORGNAME"
  9209.     !SQLDlgNames    = {    "@Caption","Verify Name and Organization", +
  9210.                         "@HELPFILE",$(!HelpSQLNTSetup),+
  9211.                         "@HELPID","145",+
  9212.                         "@DlgText","Please verify that the information you typed is correct."$(!LF)$(!LF)+
  9213.                         "If you want to change the name, company or the Product ID, "+
  9214.                         "choose Change. Otherwise, choose Continue.",+
  9215.                         "@Static1Label","Name:",+
  9216.                         "@Static1Text",$(!FullName),+
  9217.                         "@Static2Label","Company:",+
  9218.                         "@Static2Text",$(!OrgName),+
  9219.                         "@Static3Label","Product ID:",+
  9220.                         "@Static3Text",$(!ProductID),+
  9221.                         "@Continue","C&ontinue",+
  9222.                         "@Cancel","Chan&ge",+
  9223.                         "@Exit","E&xit",+
  9224.                         "@Help","&Help"}
  9225.  
  9226. [WelcomeDlgENG]
  9227.     DlgTemplate        =    "DLG_WELCOME"
  9228.     !SQLDlgNames    = {    "@Caption","Welcome", +
  9229.                         "@HELPFILE",$(!HelpSQLNTSetup),+
  9230.                         "@HELPID","100",+
  9231.                         "@DlgText","Welcome to Setup. "$(!LF)$(!LF)+
  9232.                         "The Setup program for Microsoft SQL Server ("+
  9233.                         $(!ProductVersion)") installs "$(!SQLServerBase)" on your "+
  9234.                         "computer.  Each Setup dialog box contains basic instructions for "+
  9235.                         "completing an installation.  If you want additional "+
  9236.                         "information and instructions about a dialog box or an option, "+
  9237.                         "press the Help key, F1."$(!LF)$(!LF)+
  9238.                         "To learn how to use SQL Server Setup, press F1."$(!LF)$(!LF)+
  9239.                         "To install "$(!SQLServerBase)" on your computer now, choose Continue "+
  9240.                         "or press ENTER."$(!LF)$(!LF)+
  9241.                         "To exit Setup without installing "$(!SQLServerBase)", press F3.",+
  9242.                         "@ABOUT","",+
  9243.                         "@Continue","C&ontinue",+
  9244.                         "@Help","&Help",+
  9245.                         "@Exit","E&xit"}
  9246.  
  9247. [AlreadyInstalledDlgENG]
  9248.     DlgTemplate        =    "DLG_INSTALLED"
  9249.     !SQLDlgNames    = {    "@Caption","SQL Server Already Installed",+
  9250.                         "@HELPFILE",$(!HelpSQLNTSetup),+
  9251.                         "@HELPID","146",+
  9252.                         "@DlgText1","The Setup program has detected that SQL "+
  9253.                         "Server has already been installed by:",+
  9254.                         "@RegInfo",$(!Registration),+
  9255.                         "@ProductID",$(!ProductID),+
  9256.                         "@DlgText2","It is acceptable for the legal owner to"+
  9257.                         " reinstall this product in order to update"+
  9258.                         " an existing copy or to replace a corrupted"+
  9259.                         " or missing version of the program.",+
  9260.                         "@DlgText3","You can continue to install the product, "+
  9261.                         "but you should be aware that this product "+
  9262.                         "is protected by copyright law and "+
  9263.                         "international treaties.",+
  9264.                         "@DlgText4","Unauthorized reproduction or distribution of"+
  9265.                         " this program or any portion of it may"+
  9266.                         " result in severe civil and criminal penalties"+
  9267.                         " and will be prosecuted to the maximum extent under the law.",+
  9268.                         "@Continue","C&ontinue",+
  9269.                         "@Cancel","E&xit",+
  9270.                         "@Help","&Help"}
  9271.  
  9272. [SetupDoneDlgENG]
  9273.     DlgTemplate        =    "DLG_RESTART"
  9274.     !SQLDlgNames    = {    "@Caption",$(!Setup_Title),+
  9275.                         "@DlgText",$(!MsgText)$(!LF)$(!LF)$(!AddlText),+
  9276.                         "@WindowsText","Exit to "$(!WindowsBase),+
  9277.                         "@Windows","E&xit to "$(!WindowsBase)}
  9278.  
  9279. [SetupDoneDlg95ENG]
  9280.     DlgTemplate        =    "DLG_RESTART"
  9281.     !SQLDlgNames    = {    "@Caption",$(!Setup_Title),+
  9282.                         "@DlgText",$(!MsgText)$(!AddlText),+
  9283.                         "@WindowsText","Exit to "$(!WindowsBase),+
  9284.                         "@Windows","E&xit to "$(!WindowsBase)}
  9285.  
  9286. [PopupInfo]
  9287.     DlgType        = "Info"
  9288.     DlgTemplate    = "REBOOT"
  9289.     Caption        = $(!Setup_Title)
  9290.     DlgText        = $(tmpvar)
  9291.  
  9292. [InstallTypeChoicesDlgENG]
  9293.     DlgTemplate        =    "DLG_INSTALLTYPE"
  9294.     !SQLDlgNames    = {    "@Caption",$(!Setup_Title)" - Options",+
  9295.                         "@HELPFILE",$(!HelpSQLNTSetup),+
  9296.                         "@HELPID","103",+
  9297.                         "@DEFRADIO",$(!DefRadio), +
  9298.                         "@DlgText1","Choose one of the following installation options:", +
  9299.                         "@DlgText2","When you are ready to proceed with the installation, "+
  9300.                         "choose Continue. To cancel the installation, choose Exit.",+
  9301.                         "@RadioText1","&Install SQL Server and Utilities",+
  9302.                         "@RadioText2","&Upgrade SQL Server", +
  9303.                         "@RadioText3","Install U&tilities Only",+
  9304.                         "@RadioText4","Change &Network Support",+
  9305.                         "@RadioText5","Add &Language",+
  9306.                         "@RadioText6","Rebuild &Master Database",+
  9307.                         "@RadioText7","Set Server O&ptions",+
  9308.                         "@RadioText8","Set &Security Options",+
  9309.                         "@RadioText9","&Remove SQL Server", +
  9310.                         "@Remote","R&emote",+
  9311.                         "@Continue","C&ontinue",+
  9312.                         "@Help","&Help",+
  9313.                         "@Exit","E&xit"}
  9314.  
  9315. [NewInstallOptionsDlgENG]
  9316.     DlgTemplate        =    "DLG_NEWINSTALL"
  9317.     !SQLDlgNames    = {    "@Caption"," Installation Options", +
  9318.                         "@HELPFILE",$(!HelpSQLNTSetup),+
  9319.                         "@HELPID","104",+
  9320.                         "@DlgText1","Select or clear an option by clicking a check box.", +
  9321.                         "@DlgText2","Select individual characteristics for an option by choosing the appropriate button.", +
  9322.                         "@DlgCharSet","Character Set ...............................................................", +
  9323.                         "@DlgSortOrder","Sort Order ....................................................................", +
  9324.                         "@DlgSetText","Se&ts...", +
  9325.                         "@DlgOrdersText","O&rders...", +
  9326.                         "@DlgNetText","&Networks...", +
  9327.                         "@DlgSetupText","C&ontinue", +
  9328.                         "@DlgBackText","&Back", +
  9329.                         "@DlgExitText","E&xit", +
  9330.                         "@DlgHelpText","&Help",+
  9331.                         "@DlgAddlNets","Additional Network Support ...........................................", +
  9332.                         "@AutoStart","&Auto Start SQL Server at boot time",+
  9333.                         "@AutoStartMonitor","Auto Start SQL &Executive at boot time" }
  9334.  
  9335. [CharSetsDlgENG]
  9336.     DlgTemplate        =    "DLG_SINGLELIST"
  9337.     !SQLDlgNames    = {    "@Caption","Select Character Set", +
  9338.                         "@HELPFILE",$(!HelpSQLNTSetup),+
  9339.                         "@HELPID","105",+
  9340.                         "@OK","&OK","@Cancel","&Cancel","@Help","&Help",+
  9341.                         "@DEFLISTITEM",$(DefListItem),+
  9342.                         "@DlgText1","Select Character &Set:",+
  9343.                         "@DlgText2","Important: It is critical that you select the correct character "+
  9344.                         "set.  If you later need to change the selected character set, you will need "+
  9345.                         "to rebuild your databases and reload your data",+
  9346.                         "@DlgText3","For information on character sets, choose the Help button or press F1"}
  9347.  
  9348. [SortOrderDlgENG]
  9349.     DlgTemplate        =    "DLG_SINGLEWIDELIST"
  9350.     !SQLDlgNames    = {    "@Caption","Select Sort Order", +
  9351.                         "@HELPFILE",$(!HelpSQLNTSetup),+
  9352.                         "@HELPID","106",+
  9353.                         "@DEFLISTITEM",$(DefListItem),+
  9354.                         "@OK","&OK","@Cancel","&Cancel","@Help","&Help",+
  9355.                         "@DlgText1","Sort O&rder:",+
  9356.                         "@DlgText2","Important: It is critical that you select the correct sort "+
  9357.                         "order.  If you later need to change the selected sort order, you will need "+
  9358.                         "to rebuild your databases and reload your data",+
  9359.                         "@DlgText3","For information on sort orders, choose the Help button or press F1"}
  9360.  
  9361. [NetworkDlgENG]
  9362.     DlgTemplate        =    "DLG_SINGLEMULTLIST"
  9363.     !SQLDlgNames    = {    "@Caption","Select Network Protocols", +
  9364.                         "@Checks","ON",+
  9365.                         "@HELPFILE",$(!HelpSQLNTSetup),+
  9366.                         "@HELPID","107",+
  9367.                         "@OK","&OK","@Cancel","&Cancel","@Help","&Help",+
  9368.                         "@DlgText1","Install/Uninstall &Networks:",+
  9369.                         "@DlgText2","" }
  9370.  
  9371. [NetworkDlgExENG]
  9372.     DlgTemplate        =    "DLG_SINGLEMULTLISTBACK"
  9373.     !SQLDlgNames    = {    "@Caption","Select Network Protocols",+
  9374.                         "@Checks","ON",+
  9375.                         "@HELPFILE",$(!HelpSQLNTSetup),+
  9376.                         "@HELPID","107",+
  9377.                         "@OK","&OK","@Cancel","E&xit","@Help","&Help","@Back","&Back",+
  9378.                         "@DlgText1","Install/Uninstall &Networks:",+
  9379.                         "@DlgText2","" }
  9380.  
  9381. [InstallCompletedENG]
  9382.     DlgTemplate        =    "DLG_REBREST"
  9383.     !SQLDlgNames    = {    "@Caption",$(!Setup_Title)" - Completed", +
  9384.                         "@DlgText",$(!RebootType)$(!LF)$(!LF)+
  9385.                         "The system paths have been updated and will become effective "+
  9386.                         "when the system is rebooted. Be sure to remove any floppy disks from "+
  9387.                         "the computer before you reboot."$(!LF)$(!AddlText),+
  9388.                         "@WindowsText","Exit to "$(!WindowsBase)".",+
  9389.                         "@Windows","E&xit to "$(!WindowsBase)".",+
  9390.                         "@RebootLater","Reboot later.",+
  9391.                         "@RebootText",$(!RebootText),+
  9392.                         "@Reboot","&Reboot"}
  9393.  
  9394. [InstallCompletedLocalENG]
  9395.     !RebootText = "Reboot"
  9396.  
  9397. [InstallCompletedRemoteENG]
  9398.     !RebootText = "Remote Reboot"
  9399.  
  9400. [UpgradeWarning1ENG]
  9401.     !DlgTemplate    =    "DLG_THREEBUTS"
  9402.     !SQLDlgNames    = {    "@Caption","Upgrade SQL Server",+
  9403.                         "@HELPFILE",$(!HelpSQLNTSetup),+
  9404.                         "@HELPID","148",+
  9405.                         "@DlgText1","It is advisable that you back up all your databases (including the master database) before upgrading your installation of Microsoft SQL Server."+
  9406.                         " In addition you should run chkupg.exe to check for potential upgrade problems.",+
  9407.                         "@DlgText2","If you want to terminate the upgrade, choose Exit.",+
  9408.                         "@DlgText3","To proceed with the upgrade, choose Resume.",+
  9409.                         "@Continue","&Resume",+
  9410.                         "@Back","&Back",+
  9411.                         "@Exit","E&xit",+
  9412.                         "@Help","&Help"}
  9413.  
  9414. [UpgradeWarning2ENG]
  9415.     !DlgTemplate    =    "DLG_TWOBUTS"
  9416.     !SQLDlgNames    = {    "@Caption","Upgrade SQL Server",+
  9417.                         "@DlgText1","Are you sure you want to continue with upgrading SQL Server?", +
  9418.                         "@DlgText2","If you want to terminate the upgrade, choose Exit.",+
  9419.                         "@DlgText3","To proceed with the upgrade, choose Resume.",+
  9420.                         "@Continue","&Resume",+
  9421.                         "@Exit","E&xit"}
  9422.  
  9423. [RebuildOptionsDlg]
  9424.     DlgTemplate        =    "DLG_REBUILD"
  9425.     !SQLDlgNames    = {    "@Caption",$(!Setup_Title)" Rebuild Options", +
  9426.                         "@HELPFILE",$(!HelpSQLNTSetup),+
  9427.                         "@HELPID","130",+
  9428.                         "@DlgText1","Select the options you want to use for rebuilding the MASTER device by selecting "+
  9429.                         "the appropriate button.",+
  9430.                         "@DlgCharSet","Character Set ...............................................................", +
  9431.                         "@DlgSortOrder","Sort Order ....................................................................", +
  9432.                         "@DlgSetText","Se&ts...", +
  9433.                         "@DlgOrdersText","O&rders...", +
  9434.                         "@DlgSetupText","C&ontinue", +
  9435.                         "@DlgBackText","&Back", +
  9436.                         "@DlgExitText","E&xit", +
  9437.                         "@DlgHelpText","&Help"}
  9438.  
  9439. [RebuildDlgENG]
  9440.     DlgTemplate        =    "DLG_THREEBUTS"
  9441.     !SQLDlgNames    = {    "@Caption","Rebuild MASTER Database",+
  9442.                         "@HELPFILE",$(!HelpSQLNTSetup),+
  9443.                         "@HELPID","147",+
  9444.                         "@DlgText1","Rebuilding the master database will result in the "+
  9445.                         "loss of previously created databases.", +
  9446.                         "@DlgText2","If you want to terminate the rebuild, choose Exit.",+
  9447.                         "@DlgText3","To proceed with the rebuild, choose Resume.",+
  9448.                         "@Continue","&Resume",+
  9449.                         "@Back","&Back",+
  9450.                         "@Exit","E&xit",+
  9451.                         "@Help","&Help"}
  9452.  
  9453. [NukeDlgENG]
  9454.     DlgTemplate        =    "DLG_NUKE"
  9455.     !SQLDlgNames    = {    "@Caption","Remove SQL Server",+
  9456.                         "@DlgText1","Selecting this option will remove SQL Server from this computer. If you choose to "+
  9457.                         "remove the SQL Server files from "$(!SQLPath)", all information will be lost and cannot be recovered.", +
  9458.                         "@DlgText2","If you want to terminate the operation, choose Exit.",+
  9459.                         "@DlgText3","To proceed with removing SQL Server, choose Resume.",+
  9460.                         "@Check1","Re&move files from: "$(!SQLPath),+
  9461.                         "@Continue","&Resume",+
  9462.                         "@Back","&Back",+
  9463.                         "@Exit","E&xit"}
  9464.  
  9465. [ServerParamsDlgENG]
  9466.     DlgTemplate        =    "DLG_SVR_PARAMS"
  9467.     !SQLDlgNames    = {    "@Caption","Server Parameters",+
  9468.                         "@HELPFILE",$(!HelpSQLNTSetup),+
  9469.                         "@HELPID","108",+
  9470.                         "@DlgText1","&Parameter:",+
  9471.                         "@DlgText2","&Existing Parameters:",+
  9472.                         "@Continue","&OK",+
  9473.                         "@Cancel","&Cancel",+
  9474.                         "@Help","&Help",+
  9475.                         "@Add","&Add",+
  9476.                         "LISTBOX_NOTIFY","",+
  9477.                         "@Remove","&Remove",+
  9478.                         "@Exit","E&xit"}
  9479.  
  9480. [GetPathDlgENG]
  9481.     DlgTemplate        =    $(!Template)
  9482.     !SQLDlgNames    = {    "@Caption",$(!SQLDLGPath),+
  9483.                         "@HELPFILE",$(!HelpSQLNTSetup),+
  9484.                         "@HELPID",$(!HelpID),+
  9485.                         "@DlgText1",$(!Text1),+
  9486.                         "@DlgText2",$(!Text2),+
  9487.                         "@Edit1Label",$(!EditLabel),+
  9488.                         "@Edit2Label",$(!Edit2Label),+
  9489.                         "@EDITIN1",$(!EditIn),+
  9490.                         "@EDITLEN1","256",+
  9491.                         "@Continue","C&ontinue",+
  9492.                         "@Help","&Help",+
  9493.                         "@Back","&Back",+
  9494.                         "@Exit",$(!Ex)}
  9495.  
  9496. [GetSpaceSQLPathDlgENG]
  9497.     DlgTemplate        =    "DLG_SPACESQLPATH"
  9498.     !DefInPath        =    $(!DefSQLPath)
  9499.     !SQLDlgNames    = {    "@Caption","SQL Server Installation Path",+
  9500.                                  "@HELPFILE",$(!HelpSQLNTSetup),+
  9501.                                  "@HELPID","112",+
  9502.                                  "@DlgText1","The Setup program will copy the SQL Server files into the "+
  9503.                                              "following drive and directory:",+
  9504.                                  "@DlgText4","Dri&ve:",+
  9505.                                  "@DlgText5","&Directory:",+
  9506.                                  "@DlgSpaceReq","Required Space:",+
  9507.                                  "@DlgSpaceAvail","Available Space:",+
  9508.                                  "@EDITIN1","",+
  9509.                                  "@EDITLEN1","256",+
  9510.                                  "@Continue","C&ontinue",+
  9511.                                  "@Help","&Help",+
  9512.                                  "@Back","&Back",+
  9513.                                  "@Exit","E&xit"}
  9514.  
  9515. [GetSQLPathDlg]
  9516.         DlgTemplate     =       "DLG_NEWSQLPATH"
  9517.         !DefInPath      =       $(!DefSQLPath)
  9518.         !SQLDlgNames    =       {"@Caption","SQL Server Installation Path",+
  9519.                                  "@HELPFILE",$(!HelpSQLNTSetup),+
  9520.                                  "@HELPID","101",+
  9521.                                  "@DlgText1","Please specify where the Setup program can find the existing SQL Server "+
  9522.                                              "installation.",+
  9523.                                  "@DlgText2","To instruct Setup to use the SQL Server system files in a different directory on the "+
  9524.                                              "selected drive, use the BACKSPACE key to delete characters, and then "+
  9525.                                              "type the directory containing SQL Server system files you want Setup to use.",+
  9526.                                  "@DlgText3","To instruct Setup to use the SQL Server system files on a different drive, in the "+
  9527.                                              " Drive box, select a drive letter from the list of available drives.",+
  9528.                                  "@DlgText4","Dri&ve:",+
  9529.                                  "@DlgText5","&Directory:",+
  9530.                                  "@EDITIN1","",+
  9531.                                  "@EDITLEN1","256",+
  9532.                                  "@Continue","C&ontinue",+
  9533.                                  "@Help","&Help",+
  9534.                                  "@Back","&Back",+
  9535.                                  "@Exit","E&xit"}
  9536.  
  9537. [GetSpaceMasterPathDlg]
  9538.         DlgTemplate     =       "DLG_SPACEMASTERPATH"
  9539.         !SQLDlgNames    =       {"@Caption","MASTER Device Creation",+
  9540.                                  "@HELPFILE",$(!HelpSQLNTSetup),+
  9541.                                  "@HELPID","102",+
  9542.                                  "@DlgText1","The Setup program will create the MASTER device using the following filename and drive:",+
  9543.                                  "@DlgText2","Note: The minimum MASTER device size is 25MB, but it's a good idea "+
  9544.                                              "to specify extra room for future use.",+
  9545.                                  "@DlgText3","For information on the MASTER device options, choose the Help button "+
  9546.                                              "or press F1.",+
  9547.                                  "@DlgText4","Dri&ve:",+
  9548.                                  "@DlgText5","&Directory:",+
  9549.                                  "@DlgText6","MASTER device Si&ze (MB):",+
  9550.                                  "@DlgSpaceReq","Required Space:",+
  9551.                                  "@DlgSpaceAvail","Available Space:",+
  9552.                                  "@EDITIN1","",+
  9553.                                  "@EDITLEN1","256",+
  9554.                                  "@EDITIN2",$(!DefMasterSize),+
  9555.                                  "@EDITLEN2","5",+
  9556.                                  "@EDITRESTRICT2","NUMBERS",+
  9557.                                  "@Continue","C&ontinue",+
  9558.                                  "@Help","&Help",+
  9559.                                  "@Back","&Back",+
  9560.                                  "@Exit","E&xit"}
  9561.  
  9562. [GetMasterPathDlg]
  9563.         DlgTemplate     =       "DLG_MASTERPATH"
  9564.         !SQLDlgNames    =       {"@Caption","Rebuild MASTER Device",+
  9565.                                  "@HELPFILE",$(!HelpSQLNTSetup),+
  9566.                                  "@HELPID","113",+
  9567.                                  "@DlgText1","The Setup program will rebuild the MASTER device using the following filename and drive:",+
  9568.                                  "@DlgText2","Note: The minimum MASTER device size is 25MB, but it's a good idea "+
  9569.                                              "to specify extra room for future use.",+
  9570.                                  "@DlgText3","For information on the MASTER device options, choose the Help button "+
  9571.                                              "or press F1.",+
  9572.                                  "@DlgText4","Dri&ve:",+
  9573.                                  "@DlgText5","&Directory:",+
  9574.                                  "@DlgText6","MASTER device Si&ze (MB):",+
  9575.                                  "@EDITIN1","",+
  9576.                                  "@EDITLEN1","256",+
  9577.                                  "@EDITIN2",$(!DefMasterSize),+
  9578.                                  "@EDITLEN2","5",+
  9579.                                  "@EDITRESTRICT2","NUMBERS",+
  9580.                                  "@Continue","C&ontinue",+
  9581.                                  "@Help","&Help",+
  9582.                                  "@Back","&Back",+
  9583.                                  "@Exit","E&xit"}
  9584.  
  9585. [GetUpgradeSQLPathDlgENG]
  9586.         DlgTemplate     =       "DLG_NEWSQLPATH"
  9587.         !DefInPath      =       $(!DefSQLPath)
  9588.         !SQLDlgNames    =       {"@Caption","SQL Server Upgrade Path",+
  9589.                                  "@HELPFILE",$(!HelpSQLNTSetup),+
  9590.                                  "@HELPID","117",+
  9591.                                  "@DlgText1","The Setup program will copy the SQL Server files into the "+
  9592.                                              "following drive and directory:",+
  9593.                                  "@DlgText2","To copy the SQL Server files to a different directory on the "+
  9594.                                              "selected drive, use the BACKSPACE key to delete characters, and then "+
  9595.                                              " type the directory where you want the Setup program to copy the SQL Server files.",+
  9596.                                  "@DlgText3","To copy the SQL Server files to a different drive, in the "+
  9597.                                              " Drive box, select a drive letter from the list of available drives.",+
  9598.                                  "@DlgText4","Dri&ve:",+
  9599.                                  "@DlgText5","&Directory:",+
  9600.                                  "@EDITIN1","",+
  9601.                                  "@EDITLEN1","256",+
  9602.                                  "@Continue","C&ontinue",+
  9603.                                  "@Help","&Help",+
  9604.                                  "@Back","&Back",+
  9605.                                  "@Exit","E&xit"}
  9606.  
  9607. [GetUpgradeSQLMasterPathDlg]
  9608.         DlgTemplate     =       "DLG_NEWSQLPATH"
  9609.         !DefInPath      =       $(!DefMasterPath)
  9610.         !SQLDlgNames    =       {"@Caption","SQL Server Upgrade MASTER Device Path",+
  9611.                                  "@HELPFILE",$(!HelpSQLNTSetup),+
  9612.                                  "@HELPID","127",+
  9613.                                  "@DlgText1","The Setup program will upgrade the MASTER device file "+
  9614.                                              "contained in the following drive and directory:",+
  9615.                                  "@DlgText2","To upgrade the MASTER device within in a different directory on the "+
  9616.                                              "selected drive, use the BACKSPACE key to delete characters, and then "+
  9617.                                              " type the filename of the MASTER device that the Setup program will upgrade.",+
  9618.                                  "@DlgText3","To upgrade the MASTER device on a different drive, in the "+
  9619.                                              " Drive box, select a drive letter from the list of available drives.",+
  9620.                                  "@DlgText4","Dri&ve:",+
  9621.                                  "@DlgText5","&Directory:",+
  9622.                                  "@EDITIN1","",+
  9623.                                  "@EDITLEN1","256",+
  9624.                                  "@Continue","C&ontinue",+
  9625.                                  "@Help","&Help",+
  9626.                                  "@Back","&Back",+
  9627.                                  "@Exit","E&xit"}
  9628.  
  9629.  
  9630. [GetSpaceUtilOptsDlg]
  9631.         DlgTemplate     =       "DLG_CLIENT_UTILS"
  9632.         !DefInPath      =       $(!DefSQLPath)
  9633.         !SQLDlgNames    =       {"@Caption","Install Client Utilities",+
  9634.                                  "@HELPFILE",$(!HelpSQLNTSetup),+
  9635.                                  "@HELPID","110",+
  9636.                                  "@DlgText1","The Setup program will copy the SQL Server utility files into the "+
  9637.                                              "following drive and directory:",+
  9638.                                  "@DlgText4","Dri&ve:",+
  9639.                                  "@DlgText5","&Directory:",+
  9640.                                  "@DlgText6","Utilities to be installed:",+
  9641.                                  "@Chk1","BCP",+
  9642.                                  "@Chk2","ISQL/w",+
  9643.                                  "@Chk3","SQL Enterprise Manager",+
  9644.                                  "@Chk4","SQL Security Manager",+
  9645.                                  "@Chk5","Configuration Diagnostics",+
  9646.                                  "@Chk6","MS Query",+
  9647.                                  "@Chk7","SQL Web Page Wizard",+
  9648.                                  "@Chk8","MS DTC Client Support",+
  9649.                                  "@Chk9","SQL Trace Utility",+
  9650.                                  "@DlgSpaceReq","Required Space:",+
  9651.                                  "@DlgSpaceAvail","Available Space:",+
  9652.                                  "@EDITIN1","",+
  9653.                                  "@EDITLEN1","256",+
  9654.                                  "@Continue","C&ontinue",+
  9655.                                  "@Help","&Help",+
  9656.                                  "@Back","&Back",+
  9657.                                  "@Exit","E&xit"}
  9658.  
  9659. [GetNetLibPathDlgENG]
  9660.         !Template       =       "DLG_SQLPATHBACK"
  9661.         !NoNameText     =       DBNoPathENG
  9662.         !PermitNullName =       "NO"
  9663.         !CreatePathPrompt=      "NO"
  9664.         !AutoPopoff     =       "NO"
  9665.         !ExtraEdit      =       ""
  9666.         !Text1          =       "The Setup program will copy the following user-defined Net-Library "+
  9667.                                 "to the hard disk."
  9668.         !Text2          =       "To copy the Net-Library file from a different "+
  9669.                                 "location, use the BACKSPACE key to delete "+
  9670.                                 "characters, and then type the drive, path and filename "+
  9671.                                 "from which you want the Setup program to copy the Net-Library file."
  9672.         !EditIn         =       $(!DefNETPath)
  9673.         !EditLabel      =       "&Path:"
  9674.         !HelpID         =       "114"
  9675.         !Ex             =       "E&xit"
  9676.  
  9677. [GetSortFileDlgENG]
  9678.         !Template       =       "DLG_SQLLONGEDITEXTRA"
  9679.         !NoNameText     =       DBNoPathENG
  9680.         !PermitNullName =       "NO"
  9681.         !CreatePathPrompt=      "NO"
  9682.         !AutoPopoff     =       "NO"
  9683.         !ExtraEdit      =       "EDIT2"
  9684.         !ExtraEditFail  =       "Please supply the sort order ID."
  9685.         !Text1          =       "The Setup program will copy the following character set "+
  9686.                                 "file to the hard disk:"
  9687.         !Text2          =       "To copy the character set file from a different "+
  9688.                                 "location, use the BACKSPACE key to delete "+
  9689.                                 "characters, and then type the drive, path and filename "+
  9690.                                 "from which you want the Setup program to copy the character set file."
  9691.         !EditIn         =       $(!DefNETPath)
  9692.         !HelpID         =       "115"
  9693.         !EditLabel      =       "Sort &Filename:"
  9694.         !Edit2Label     =       "Sort &Order Number:"
  9695.         !Ex             =       "E&xit"
  9696.  
  9697. [GetLangFileDlgENG]
  9698.         !Template       =       "DLG_SQLLONGEDIT"
  9699.         !PermitNullName =       "NO"
  9700.         !CreatePathPrompt=      "NO"
  9701.         !AutoPopoff     =       "YES"
  9702.         !Text1          =       "The Setup program will copy the following language file "+
  9703.                                 "to the hard disk:"
  9704.         !Text2          =       "To copy the language file from a different "+
  9705.                                 "location, use the BACKSPACE key to delete "+
  9706.                                 "characters, and then type the drive, path and filename "+
  9707.                                 "from which you want the Setup program to copy the language files."
  9708.         !EditIn         =       $(!DefNETPath)
  9709.         !HelpID         =       "116"
  9710.         !EditLabel      =       "&Path:"
  9711.         !Ex             =       "E&xit"
  9712.  
  9713. [GetSAPasswordDlgENG]
  9714.         DlgTemplate     =       "DLG_SQLPASSWORDEDIT"
  9715.         !PermitNullName =       "YES"
  9716.         !CreatePathPrompt=      "NO"
  9717.         !AutoPopoff     =       "YES"
  9718.         !Text1          =       "Please enter and confirm the SA password that the upgrade "+
  9719.                                 "will use to log in to the SQL Server."
  9720.         !Text2          =       "To enter a different SA password, "+
  9721.                                 "use the BACKSPACE key to delete "+
  9722.                                 "characters, and then type the password "+
  9723.                                 "you want the Setup program to use when upgrading."
  9724.         !SQLDlgNames    =       {"@Caption","SA Password",+
  9725.                                  "@HELPFILE",$(!HelpSQLNTSetup),+
  9726.                                  "@HELPID",118,+
  9727.                                  "@DlgText1",$(!Text1),+
  9728.                                  "@DlgText2",$(!Text2),+
  9729.                                  "@Edit1Label","&SA Password:",+
  9730.                                  "@Edit2Label","&Confirm Password:",+
  9731.                                  "@EDITIN1","",+
  9732.                                  "@EDITLEN1","256",+
  9733.                                  "@EDITIN2","",+
  9734.                                  "@EDITLEN2","256",+
  9735.                                  "@Continue","C&ontinue",+
  9736.                                  "@Help","&Help",+
  9737.                                  "@Back","&Back",+
  9738.                                  "@Exit","E&xit"}
  9739.  
  9740. [GetMailInfoDlgENG]
  9741.         DlgTemplate     =       "DLG_MAILINFOEDIT"
  9742.         !PermitNullName =       "YES"
  9743.         !CreatePathPrompt=      "NO"
  9744.         !AutoPopoff     =       "YES"
  9745.         !Text1          =       "In order to auto start the mail client, a valid mail login name "+
  9746.                                 "and password must be entered. "
  9747.         !SQLDlgNames    =       {"@Caption","Mail Login",+
  9748.                                  "@HELPFILE",$(!HelpSQLNTSetup),+
  9749.                                  "@HELPID",132,+
  9750.                                  "@DlgText1",$(!Text1),+
  9751.                                  "@Edit1Label","&Mail Login Name:",+
  9752.                                  "@Edit2Label","Mail &Password:",+
  9753.                                  "@Edit3Label","&Confirm Password:",+
  9754.                                  "@Chk1","Copy &SQLMail configuration from current user account",+
  9755.                                  "@EDITIN1","",+
  9756.                                  "@EDITLEN1","256",+
  9757.                                  "@EDITIN2","",+
  9758.                                  "@EDITLEN2","256",+
  9759.                                  "@EDITIN2","",+
  9760.                                  "@EDITLEN2","256",+
  9761.                                  "@Continue","C&ontinue",+
  9762.                                  "@Help","&Help",+
  9763.                                  "@Back","&Back",+
  9764.                                  "@Exit","E&xit"}
  9765.  
  9766. [GetStreetNameDlgENG]
  9767.         !Template       =       "DLG_SQLLONGEDIT"
  9768.         !NoNameText     =       NoStreetENG
  9769.         !PermitNullName =       "NO"
  9770.         !CreatePathPrompt=      "NO"
  9771.         !AutoPopoff     =       "YES"
  9772.         !Text1          =       "SQL Server will use the following StreetTalk PC-based service name:"
  9773.         !Text2          =       "To enter a different PC-based service name, "+
  9774.                                 "use the BACKSPACE key to delete "+
  9775.                                 "characters, and then type the PC-based service name "+
  9776.                                 "you want SQL Server to use."
  9777.         !EditIn         =       $(!StreetName)
  9778.         !EditLabel      =       "&Service Name:"
  9779.         !HelpID         =       "140"
  9780.         !Ex             =       "E&xit"
  9781.         !SQLDLGPath     =       "Street Talk service name"
  9782.  
  9783. [GetNamedPipesDlgENG]
  9784.         !Template       =       "DLG_SQLLONGEDIT"
  9785.         !NoNameText     =       NoPipeENG
  9786.         !PermitNullName =       "NO"
  9787.         !CreatePathPrompt=      "NO"
  9788.         !AutoPopoff     =       "YES"
  9789.         !Text1          =       "SQL Server will use the following Named Pipe name:"
  9790.         !Text2          =       "To enter a different Named Pipe name, "+
  9791.                                 "use the BACKSPACE key to delete "+
  9792.                                 "characters, and then type the Named Pipe name "+
  9793.                                 "you want SQL Server to use."
  9794.         !EditIn         =       $(!ServerNMPipeName)
  9795.         !EditLabel      =       "&Named Pipe name:"
  9796.         !HelpID         =       "150"
  9797.         !Ex             =       "E&xit"
  9798.         !SQLDLGPath     =       "Named Pipe name"
  9799.  
  9800. [GetTCPIPSocketDlgENG]
  9801.         !Template       =       "DLG_SQLLONGEDIT"
  9802.         !PermitNullName =       "NO"
  9803.         !CreatePathPrompt=      "NO"
  9804.         !AutoPopoff     =       "YES"
  9805.         !NoNameText     =       NoTCPIPSocketENG
  9806.         !Text1          =       "SQL Server will listen on the following TCP/IP port number: "
  9807.         !Text2          =       "To enter a different TCP/IP port number, "+
  9808.                                 "use the BACKSPACE key to delete "+
  9809.                                 "characters, and then type the TCP/IP port number "+
  9810.                                 "you want SQL Server to listen on."
  9811.         !EditLabel      =       "&Port Number:"
  9812.         !EditIn         =       $(!TCPIPSocketNumber)
  9813.         !HelpID         =       "121"
  9814.         !Ex             =       "E&xit"
  9815.         !SQLDLGPath     =       "TCP/IP Socket Number"
  9816.  
  9817. [GetServiceNameDlgENG]
  9818.         !Template       =       "DLG_SQLLONGEDIT"
  9819.         !NoNameText     =       NoServiceENG
  9820.         !PermitNullName =       "NO"
  9821.         !CreatePathPrompt=      "NO"
  9822.         !AutoPopoff     =       "YES"
  9823.         !Text1          =       "SQL Server will use the following Novell Bindery service name:"
  9824.         !Text2          =       "To enter a different Novell Bindery service name, "+
  9825.                                 "use the BACKSPACE key to delete "+
  9826.                                 "characters, and then type the Novell Bindery service name "+
  9827.                                 "you want the SQL Server to use."
  9828.         !EditIn         =       $(!ServiceName)
  9829.         !EditLabel      =       "&Service Name:"
  9830.         !HelpID         =       "122"
  9831.         !Ex             =       "E&xit"
  9832.         !SQLDLGPath     =       "Novell Bindery service name"
  9833.  
  9834. [GetADSPNameDlgENG]
  9835.         !Template       =       "DLG_SQLLONGEDIT"
  9836.         !NoNameText     =       NoADSPENG
  9837.         !PermitNullName =       "NO"
  9838.         !CreatePathPrompt=      "NO"
  9839.         !AutoPopoff     =       "YES"
  9840.         !Text1          =       "SQL Server will use the following Apple Talk service object name:"
  9841.         !Text2          =       "To enter a different Apple Talk service object name, "+
  9842.                                 "use the BACKSPACE key to delete "+
  9843.                                 "characters, and then type the Apple Talk service object name "+
  9844.                                 "you want the SQL Server to use."
  9845.         !EditIn         =       $(!ADSPServiceName)
  9846.         !EditLabel      =       "&Service Name:"
  9847.         !HelpID         =       "142"
  9848.         !Ex             =       "E&xit"
  9849.         !SQLDLGPath     =       "Apple Talk service object name"
  9850.  
  9851.  
  9852. [GetDECNetNameDlgENG]
  9853.         !Template       =       "DLG_SQLLONGEDIT"
  9854.         !NoNameText     =       NoDECNetENG
  9855.         !PermitNullName =       "NO"
  9856.         !CreatePathPrompt=      "NO"
  9857.         !AutoPopoff     =       "YES"
  9858.         !Text1          =       "SQL Server will use the following DECNet Object ID:"
  9859.         !Text2          =       "To enter a different DECNet Object ID, "+
  9860.                                 "use the BACKSPACE key to delete "+
  9861.                                 "characters, and then type the DECNet Object ID "+
  9862.                                 "you want the SQL Server to use."
  9863.         !EditIn         =       $(!DECNetObjectID)
  9864.         !EditLabel      =       "&Object ID:"
  9865.         !HelpID         =       "141"
  9866.         !Ex             =       "E&xit"
  9867.         !SQLDLGPath     =       "DECNet Object ID"
  9868.  
  9869. [GetMultiProtEncryptDlgENG]
  9870.         DlgTemplate     =       "DLG_ONECHECK"
  9871.         !SQLDlgNames    =       {"@Caption","Multi Protocol Encryption" ,+
  9872.                                  "@HELPFILE",$(!HelpSQLNTSetup),+
  9873.                                  "@HELPID","151",+
  9874.                                  "@DlgText1","SQL Server can enable encryption on Multi Protocol connections.",+
  9875.                                  "@DlgText2","To enable encryption, check the box above, "+
  9876.                                               "to disable encryption uncheck the box.",+
  9877.                                  "@Chk1","&Enable Multi Protocol Encryption",+
  9878.                                  "@Continue","C&ontinue",+
  9879.                                  "@Help","&Help",+
  9880.                                  "@Back","&Back",+
  9881.                                  "@Exit","E&xit"}
  9882.  
  9883. [GetNetAddressDlgENG]
  9884.         !Template       =       "DLG_SQLLONGEDIT"
  9885.         !NoNameText     =       NoNetENG
  9886.         !PermitNullName =       "NO"
  9887.         !CreatePathPrompt=      "NO"
  9888.         !AutoPopoff     =       "YES"
  9889.         !Text1          =       "The Setup program will enter the following network "+
  9890.                                 "address associated with the "$(!UserDefinedName)" Net-Library in the Windows NT Registry:"
  9891.         !Text2          =       "To enter a different network address, "+
  9892.                                 "use the BACKSPACE key to delete "+
  9893.                                 "characters, and then type the network address "+
  9894.                                 "you want the Setup program to enter in the Windows NT Registry."
  9895.         !EditIn         =       $(!NetAddress)
  9896.         !EditLabel      =       "&Network Address:"
  9897.         !HelpID         =       "123"
  9898.         !Ex             =       "E&xit"
  9899.         !SQLDLGPath     =       $(!UserDefinedName)
  9900.  
  9901. [GetLangInfoDlgENG]
  9902.         DlgTemplate     =       "DLG_DUALEDIT"
  9903.         !SQLDlgNames    =       {"@Caption","Select Language",+
  9904.                                  "@HELPFILE",$(!HelpSQLNTSetup),+
  9905.                                  "@HELPID","124",+
  9906.                                  "@DlgText1","To install a language, specify the "+
  9907.                                  "official language name and the SQL Server SA password. ",+
  9908.                                  "@DlgText2","To change the language name or the SA password, "+
  9909.                                  "use the BACKSPACE key to delete characters, and "+
  9910.                                  "then type the information you want the Setup program to use.",+
  9911.                                  "@EditLabel1","Language &Name:",+
  9912.                                  "@EDITLEN1","30",+
  9913.                                  "@EditLabel2","SA &Password:",+
  9914.                                  "@EDITLEN2","30",+
  9915.                                  "@Chk1","&Default Language",+
  9916.                                  "@Continue","C&ontinue",+
  9917.                                  "@Exit","E&xit",+
  9918.                                  "@Back","&Back",+
  9919.                                  "@Help","&Help"}
  9920.  
  9921. [ServerOptsDlgENG]
  9922.         DlgTemplate     =       "DLG_SERVEROPTIONS"
  9923.         !SQLDlgNames    =       {"@Caption","Select Server Options",+
  9924.                                  "@HELPFILE",$(!HelpSQLNTSetup),+
  9925.                                  "@HELPID","125",+
  9926.                                  "@DlgText1","Startup",+
  9927.                                  "@DlgText2","&Root Directory:",+
  9928.                                  "@DlgText3","Master &Database Path:",+
  9929.                                  "@DlgText4","Errorlo&g Path:",+
  9930.                                  "@Chk1","&Auto Start Server At Boot Time",+
  9931.                                  "@Chk2","Auto Start Executive At Boot Ti&me",+
  9932.                                  "@Chk7","A&uto Start Mail Client",+
  9933.                                  "@Chk4","&Windows NT Event Logging",+
  9934.                                  "@Chk5","S&QL PerfMon Integration",+
  9935.                                  "@Radio1","D&irect Response Mode",+
  9936.                                  "@Radio2","&On Demand Mode",+
  9937.                                  "@Chk8","xp_cmdsh&ell - Impersonates Client",+
  9938.                                  "@Chk9","Enable SNMP support",+
  9939.                                  "@EDITLEN1","256",+
  9940.                                  "@EDITLEN2","256",+
  9941.                                  "@EDITLEN3","256",+
  9942.                                  "@Connect","Co&nnect",+
  9943.                                  "@Continue","&Change Options",+
  9944.                                  "@Exit","E&xit",+
  9945.                                  "@Params","&Parameters",+
  9946.                                  "@TapeSup","&Tape Support",+
  9947.                                  "@MailLog","Mail &Login", +
  9948.                                  "@Back","&Back",+
  9949.                                  "@Help","&Help"}
  9950.  
  9951. [RemoteDlgENG]
  9952.         DlgTemplate     =       "DLG_REMOTE"
  9953.         !SQLDlgNames    =       {"@Caption","Remote Setup",+
  9954.                                  "@HELPFILE",$(!HelpSQLNTSetup),+
  9955.                                  "@HELPID","126",+
  9956.                                  "@DlgText1","Setup permits operations to be performed on remote computers. To perform a remote setup, you must specify a computer name "+
  9957.                                              "and select the logical drive letters that setup requires.",+
  9958.                                  "@DlgText2","The Windows NT and MASTER installation drives default initially to the SQL installation drive.",+
  9959.                                  "@Check1","&Remote Installation",+
  9960.                                  "@Radio1","&SQL Installation Drive",+
  9961.                                  "@Radio2","Windows N&T Installation Drive",+
  9962.                                  "@Radio3","&Master Database Installation Drive",+
  9963.                                  "@DlgText3","Remote Server &Name:",+
  9964.                                  "@DlgText4","Remote Logical &Drive:",+
  9965.                                  "@DEFBTNRADIO","2",+
  9966.                                  "@EDITIN1",$(!Remote),+
  9967.                                  "@EDITLEN1","30",+
  9968.                                  "@Continue","&OK",+
  9969.                                  "@Cancel",$(!ExitButton),+
  9970.                                  "@Help","&Help"}
  9971.  
  9972. [TapeTimeDlgENG]
  9973.         DlgTemplate     =       "DLG_TAPETIME"
  9974.         !SQLDlgNames    =       {"@Caption","Tape Support",+
  9975.                                  "@HELPFILE",$(!HelpSQLNTSetup),+
  9976.                                  "@HELPID","128",+
  9977.                                  "@DlgText1","SQL Server can be configured to wait a specified amount of "+
  9978.                                              "time while trying to read a tape that has not been loaded in "+
  9979.                                              "the drive. Select the appropriate tape timeout mode.",+
  9980.                                  "@DlgText2","minutes",+
  9981.                                  "@Radio1","&Wait Indefinitely",+
  9982.                                  "@Radio2","T&ry Once and Quit",+
  9983.                                  "@Radio3","Try &for ",+
  9984.                                  "@DEFBTNRADIO",$(!DefRadio),+
  9985.                                  "@EDITIN1",$(!TapeTO),+
  9986.                                  "@EDITLEN1","5",+
  9987.                                  "@EDITRESTRICT1","NUMBERS",+
  9988.                                  "@Continue","&OK",+
  9989.                                  "@Cancel","&Cancel",+
  9990.                                  "@Help","&Help"}
  9991.  
  9992. [SecurityDlgENG]
  9993.         DlgTemplate     =       "DLG_SECURITY"
  9994.         !SQLDlgNames    =       {"@Caption","Set Security Options",+
  9995.                                  "@HELPFILE",$(!HelpSQLNTSetup),+
  9996.                                  "@HELPID","129",+
  9997.                                  "@DlgText1","Login Security Mode",+
  9998.                                  "@DlgText2","Default &Login:",+
  9999.                                  "@DlgText3","Default &Domain:",+
  10000.                                  "@DlgText4","Audit Level",+
  10001.                                  "@DlgText5","Mappings",+
  10002.                                  "@Radio1","&Standard",+
  10003.                                  "@Radio2","Windows NT &Integrated",+
  10004.                                  "@Radio3","&Mixed",+
  10005.                                  "@Check1","Su&ccessful Logins",+
  10006.                                  "@Check2","&Failed Logins",+
  10007.                                  "@Check3","Set Hostname to &User Name",+
  10008.                                  "@Map1","Map _:",+
  10009.                                  "@Map2","Map #:",+
  10010.                                  "@Map3","Map $:",+
  10011.                                  "@DEFBTNRADIO",$(!DefRadio),+
  10012.                                  "@CALLCOMBOLEN1","1",+
  10013.                                  "@CALLCOMBOLEN2","1",+
  10014.                                  "@CALLCOMBOLEN3","1",+
  10015.                                  "@Continue","&OK",+
  10016.                                  "@Back","&Back",+
  10017.                                  "@Cancel","E&xit",+
  10018.                                  "@Help","&Help"}
  10019.  
  10020. [UserAccountDlgENG]
  10021.         DlgTemplate     =       "DLG_USERACCT"
  10022.         !SQLDlgNames    =       {"@Caption","SQL Executive Log On Account",+
  10023.                                  "@HELPFILE",$(!HelpSQLNTSetup),+
  10024.                                  "@HELPID","149",+
  10025.                                  "@RadioText1","&Install the SQL Executive service to log on to Windows NT as:",+
  10026.                                  "@RadioText2","Install to log on as Local &System account.",+
  10027.                                  "@Edit1Label","&Account: ",+
  10028.                                  "@Edit2Label","&Password:",+
  10029.                                  "@Edit3Label","&Confirm Pwd:",+
  10030.                                  "@EDITIN1","",+
  10031.                                  "@EDITLEN1","30",+
  10032.                                  "@EDITIN2","",+
  10033.                                  "@EDITLEN2","30",+
  10034.                                  "@EDITIN3","",+
  10035.                                  "@EDITLEN3","30",+
  10036.                                  "@Continue","C&ontinue",+
  10037.                                  "@Back","&Back",+
  10038.                                  "@Exit","E&xit",+
  10039.                                  "@Help","&Help"}
  10040.  
  10041. [VerifyAcctDlgENG]
  10042.         DlgTemplate      =      "DLG_VERIFY"
  10043.         !SQLDlgNames     =      { "@Caption","Verify Local Account",+
  10044.                                   "@DlgText1","Please wait while Setup verifies your"+
  10045.                                               " Microsoft Windows NT Local Administrator Account." }
  10046.  
  10047. [SQLBooksOnlineDlgENG]
  10048.        DlgTemplate      =       "DLG_BOOKS"
  10049.        !SQLDlgNames     =       { "@Caption","SQL Server Books Online",+
  10050.                                  "@HELPFILE",$(!HelpSQLNTSetup),+
  10051.                                  "@HELPID","138",+
  10052.                                   "@DlgText1","Select a SQL Server Books Online installation option:",+
  10053.                                   "@DlgText2","SQL Server Books Online includes Release Notes and online "+
  10054.                                               "versions of selected SQL Server print documents.",+
  10055.  
  10056.                                   "@DlgText3","Installing to run from your hard disk requires about 15 MB "+
  10057.                                               "of available space. Installing to run from CD installs fewer "+
  10058.                                               "files and requires about 1 MB of available hard disk space.",+
  10059.                                   "@RadioText1","Install on Hard &Disk",+
  10060.                                   "@RadioText2","Install to Run from &CD",+
  10061.                                   "@RadioText3","Do ¬ Install",+
  10062.                                   "@Continue","C&ontinue",+
  10063.                                   "@Back","&Back",+
  10064.                                   "@Exit","E&xit",+
  10065.                                   "@Help","&Help"}
  10066. [CheckUpgradeWarningENG]
  10067.         !DlgTemplate    =       "DLG_ONEBUT"
  10068.         !SQLDlgNames    =       {"@Caption","SQL Server Upgrade Check",+
  10069.                                  "@DlgText1",$(!MsgText)$(!LF), +
  10070.                                  "@DlgText2",$(!AddlText),+
  10071.                                  "@DlgText3","To proceed with the upgrade, choose Resume.",+
  10072.                                  "@Continue","&Resume"}
  10073.  
  10074. [LicenseWorkStaDlgENG]
  10075.         !DlgTemplate    =       "DLG_TWOBUTSONETEXT"
  10076.         !SQLDlgNames    =       { "@Caption","Licensing",+
  10077.                                   "@DlgText1","License Mode",+
  10078.                                   "@DlgText2","This SQL Workstation is licensed for a single user and allows a"+
  10079.                                               " maximum of 15 simultaneous database connections.",+
  10080.                                   "@Continue","C&ontinue",+
  10081.                                   "@Exit","E&xit"}
  10082.  
  10083. [InvalidMachineNameENG]
  10084.         !DlgTemplate    =       "DLG_THREEBUTSNOBACK"
  10085.         !SQLDlgNames    =       {"@Caption","WARNING: Invalid Machine Name",+
  10086.                                  "@HELPFILE",$(!HelpSQLNTSetup),+
  10087.                                  "@HELPID","155",+
  10088.                                  "@DlgText1","The Server name is not a valid SQL Server name and can cause problems in multi-server, replication and SQL Enterprise Manager operations.",+
  10089.                                  "@DlgText2","Press Resume to continue the installation. Use sp_addserver to correct the problem after Setup is completed.",+
  10090.                                  "@DlgText3","Press Exit to cancel installation.",+
  10091.                                  "@Continue","&Resume",+
  10092.                                  "@Exit","E&xit",+
  10093.                                  "@Help","&Help"}
  10094.  
  10095. [CantUpgradeBetaDlgENG]
  10096.         !DlgTemplate    =       "DLG_ONEBUT"
  10097.         !SQLDlgNames    =       {"@Caption","Cannot upgrade Beta",+
  10098.                                  "@DlgText1","Setup has detected an early beta version of SQL Server 6.0.", +
  10099.                                  "@DlgText2","This beta version cannot be upgraded to the released version.",+
  10100.                                  "@DlgText3","Please consult the release notes for more information.",+
  10101.                                  "@Continue","E&xit"}
  10102.  
  10103.  
  10104. [UpgradeOverSMSENG]
  10105.         !DlgTemplate    =       "DLG_TWOBUTS"
  10106.         !SQLDlgNames    =       {"@Caption","SMS - SQL Server conflict",+
  10107.                                  "@DlgText1","Setup has detected SMS version 1.0 is installed on this system.", +
  10108.                                  "@DlgText2","SMS 1.0 will not run correctly with this version of SQL Server.",+
  10109.                                  "@DlgText3","If you wish to proceed with the installation, choose Resume.",+
  10110.                                  "@Continue","&Resume",+
  10111.                                  "@Exit","E&xit"}
  10112.  
  10113.  
  10114. [SelectClientInstallDlgENG]
  10115.         !DlgTemplate    =       "DLG_SELECTCLIENT"
  10116.         !SQLDlgNames    =       {"@Caption","Install/Remove Client Utilities",+
  10117.                                  "@HELPFILE",$(!HelpSQLNTSetup),+
  10118.                                  "@HELPID","156",+
  10119.                                  "@DlgText1","Choose one of the following installation options:", +
  10120.                                  "@DlgText2","When you are ready to proceed with the installation choose "+
  10121.                                              "Continue.  To cancel the installation choose Exit.",+
  10122.                                  "@RadioText1","&Install Client Utilities",+
  10123.                                  "@RadioText2","&Remove Client Utilities and all files from "$(!DefSQLPath),+
  10124.                                  "@Continue","C&ontinue",+
  10125.                                  "@Exit","E&xit",+
  10126.                                  "@Help","&Help"}
  10127.  
  10128.  
  10129. [RemoteExitENG]
  10130.         !ExitButton     =       "E&xit"
  10131.  
  10132. [RemoteCancelENG]
  10133.         !ExitButton     =       "&Cancel"
  10134.  
  10135.  
  10136. [YesNoDlgENG]
  10137.         DlgTemplate     =       "SetupMessage"
  10138.         DlgType         =       "MessageBox"
  10139.         STF_MB_TITLE    =       $(!Setup_Title)
  10140.         STF_MB_TEXT     =       $(!YesNoQ)
  10141.         STF_MB_TYPE     =       3
  10142.         STF_MB_ICON     =       4
  10143.         STF_MB_DEF      =       1
  10144.  
  10145. [InfoMessageENG]
  10146.         DlgTemplate     =       "SetupMessage"
  10147.         DlgType         =       "MessageBox"
  10148.         STF_MB_TITLE    =       $(!Setup_Title)
  10149.         STF_MB_TEXT     =       $(!AddlText)
  10150.         STF_MB_TYPE     =       1
  10151.         STF_MB_ICON     =       2
  10152.         STF_MB_DEF      =       1
  10153.  
  10154. [ExitWarningDlgENG]
  10155.         DlgType         =       "MessageBox"
  10156.         STF_MB_TITLE    =       "Exit SQL Server Setup"
  10157.         STF_MB_TEXT     =       "Are you sure you want to exit SQL Server Setup?"
  10158.         STF_MB_TYPE     =       3
  10159.         STF_MB_ICON     =       5
  10160.         STF_MB_DEF      =       2
  10161.  
  10162. [InstallingDlgENG]
  10163.         DlgTemplate     =       "DLG_BILLBOARD"
  10164.         DlgType         =       "Billboard"
  10165.         !SQLDlgNames    =       {"@BillyBoy","Setup is now creating your master database device. "$(!LF)$(!LF)$(!PleaseWait)}
  10166.  
  10167. [MailManDlgENG]
  10168.         DlgTemplate     =       "DLG_MAILMAIN"
  10169.         DlgType         =       "Billboard"
  10170.         !SQLDlgNames    =       {"MAILPEOPLE","",+
  10171.                                  "@Bill1","Now is a great time to fill out your registration card. "+
  10172.                                           "When you send it in, Microsoft will ...",+
  10173.                                  "@Bill2","- Inform you of product updates.",+
  10174.                                  "@Bill3","- Offer you customer support.",+
  10175.                                  "@Bill4","- Provide you with information about related Microsoft products."}
  10176.  
  10177. [DLG_BillboardSearchRename]
  10178.         DlgTemplate     =       "DLG_BILLBOARD"
  10179.         DlgType         =       "Billboard"
  10180.         !SQLDlgNames    =       {"@BillyBoy","Setup is searching for existing SQL Server DLLs "+
  10181.                                              "in your path, and will rename them if any DLLs are "+
  10182.                                              "found."$(!LF)$(!LF)$(!PleaseWait)}
  10183.  
  10184. [InstLangingDlgENG]
  10185.         DlgTemplate     =       "DLG_BILLBOARD"
  10186.         DlgType         =       "Billboard"
  10187.         !SQLDlgNames    =       {"@BillyBoy","Setup is now installing your chosen language options."$(!LF)$(!LF)$(!PleaseWait)}
  10188.  
  10189. [ProgressCopyVars]
  10190.         ProCaption      =       "File copy in progress"
  10191.         ProCancel       =       "&Cancel"
  10192.         ProCancelMsg    =       "Setup cannot run correctly until this operation is"$(!LF)+
  10193.                                 "complete.  Are you sure you want to cancel?"
  10194.         ProCancelCap    =       "SQL Server for "$(!WindowsBase)" Setup Warning"
  10195.         ProText1        =       "Copying "
  10196.         ProText2        =       "         to "
  10197.  
  10198. [BillboardRunningNConnSQLENG]
  10199.         !BillName       =       "Setup is now starting SQL Server and verifying its state."$(!LF)$(!LF)$(!PleaseWait)
  10200.  
  10201. [BillboardCharsetENG]
  10202.         !BillName       =       "Setup is now installing your chosen character set and sort order."$(!LF)$(!LF)$(!PleaseWait)
  10203.  
  10204. [BillboardIndexingENG]
  10205.         !BillName       =       "SQL Server is now re-indexing its system tables."$(!LF)$(!LF)$(!PleaseWait)
  10206.  
  10207. [BillboardInstScriptsENG]
  10208.         !BillName       =       "Setup is now installing the initial SQL Server configuration."$(!LF)$(!LF)$(!PleaseWait)
  10209.  
  10210. [BillboardSCMENG]
  10211.         !BillName       =       "Setup is now updating the Service Control Manager."$(!LF)$(!LF)$(!PleaseWait)
  10212.  
  10213. [BillboardUpgradingENG]
  10214.         !BillName       =       "Setup is now upgrading SQL Server."$(!LF)$(!LF)$(!PleaseWait)
  10215.  
  10216. [BillboardOleENG]
  10217.         !BillName       =       "SQL Server is now updating the OLE registration database."$(!LF)$(!LF)$(!PleaseWait)
  10218.  
  10219. [BillboardODBCENG]
  10220.         !BillName       =       "SQL Server is now installing ODBC SQL Server driver."$(!LF)$(!LF)$(!PleaseWait)
  10221.  
  10222. [STR_BillboardPrepUpgrade]
  10223.         !BillName       =       "Setup is now preparing to upgrade SQL Server."$(!LF)$(!LF)$(!PleaseWait)
  10224.  
  10225. [BillboardRemoveOldENG]
  10226.         !BillName       =       "Setup is now removing obsolete SQL Server 4.2x files."$(!LF)$(!LF)$(!PleaseWait)
  10227.  
  10228. [InsufficientPriv]
  10229.         !AddlText       =       "You have insufficient privileges to perform these operations."
  10230.  
  10231. [STR_InferiorOS]
  10232.         !AddlText       =       $(!Setup_Title)" requires Microsoft Windows NT Version 3.51 or later."
  10233.  
  10234. [STR_InvalidSystemAdmin]
  10235.         !AddlText       =       "Setup does not have access to the SQL Server Registry key. You must be logged in to Windows NT as a valid System Administrator of SQL Server in order to access this key. "+
  10236.                                 $(!LF)$(!LF)"This permission defaults to the local Administrators group and can be changed using SQL Security Manager."
  10237.  
  10238. [InsufficientMemENG]
  10239.         !AddlText       =       "This computer has insufficient memory to run SQL Server for Windows NT. You cannot proceed with the installation."
  10240.  
  10241. [ErrorUpdatingRegistryENG]
  10242.         !AddlText       =       "An error occurred while updating the "$(!WindowsBase)" Registry."
  10243.  
  10244. [FileCouldNotBeCopiedENG]
  10245.         !AddlText       =       "The files could not be copied."
  10246.  
  10247. [FileDoesntExistENG]
  10248.         !AddlText       =       "The file you specified does not exist."
  10249.  
  10250. [DBNoPathENG]
  10251.         !AddlText       =       "You must specify a path."
  10252.  
  10253. [NoSizeENG]
  10254.         !AddlText       =       "You must enter a database size."
  10255.  
  10256. [ServiceErrorENG]
  10257.         !AddlText       =       "An error occurred while accessing the Service Control Manager."
  10258.  
  10259. [DBSizeInvalidENG]
  10260.         !AddlText       =       "The value you entered for the database size is too small or is not a valid number."
  10261.  
  10262. [MasterMustExistENG]
  10263.         !AddlText       =       "The master database file must be present for an upgrade."
  10264.  
  10265. [STR_DuplicateMap]
  10266.         !AddlText       =       "All map values must be unique."
  10267.  
  10268. [DBNoNameNOrgENG]
  10269.         !AddlText       =       "You must enter a name and an organization."
  10270.  
  10271. [DBNoNameENG]
  10272.         !AddlText       =       "You must enter a name."
  10273.  
  10274. [DBNoDatENG]
  10275.         !AddlText       =       "You must specify a .DAT file."
  10276.  
  10277. [NoNetsENG]
  10278.         !AddlText       =       "You have not selected any networks."
  10279.  
  10280. [NoUtilsENG]
  10281.         !AddlText       =       "You have not selected any utilities."
  10282.  
  10283. [NoSQLServerENG]
  10284.         !AddlText       =       "The SQL Server could not be found. Please check the error/event log to ensure that the server is running."
  10285.  
  10286. [NoServerNameENG]
  10287.         !AddlText       =       "You must enter a SQL Server name."
  10288.  
  10289. [NoStreetENG]
  10290.         !AddlText       =       "You must enter a StreetTalk name."
  10291.  
  10292. [NoPipeENG]
  10293.         !AddlText       =       "You must enter a full named pipe name."
  10294.  
  10295. [NoServiceENG]
  10296.         !AddlText       =       "You must enter a Novell Bindery service name."
  10297.  
  10298. [NoADSPENG]
  10299.         !AddlText       =       "You must enter a Apple Talk object name."
  10300.  
  10301. [NoDECNetENG]
  10302.         !AddlText       =       "You must enter a DECNet Object ID."
  10303.  
  10304.  
  10305. [NoNetENG]
  10306.         !AddlText       =       "You must enter a network address."
  10307.  
  10308. [NoLangInfoENG]
  10309.         !AddlText       =       "You must enter the language information requested."
  10310.  
  10311. [CannotAllocUnusedDriveENG]
  10312.         !AddlText       =       "Setup cannot allocate a free logical drive."
  10313.  
  10314. [InsertDiskENG]
  10315.         !AddlText       =       "Insert the disk in drive "$(!TmpDrive)
  10316.  
  10317. [STR_InsufficientDiskSpace]
  10318.         !AddlText       =       "There is insufficient disk space on this drive."
  10319.  
  10320. [RegistryIntegrityENG]
  10321.         !AddlText       =       "The SQL Server Registry key integrity is suspect."
  10322.  
  10323. [ErrorReadRegistryENG]
  10324.         !AddlText       =       "An error occurred while reading the "$(!WindowsBase)" Registry."
  10325.  
  10326. [STR_CompletionNetworks]
  10327.         !MsgText        =       "The SQL Server ("$(!ProductVersion)") Net-Libraries are now updated."$(!LF)$(!LF)+
  10328.                                 "The changes will become effective the next time SQL Server is started."
  10329.  
  10330. [CompletionNewCharSortENG]
  10331.         !MsgText        =       "The SQL Server ("$(!ProductVersion)") character sets and sort orders are now updated."
  10332.  
  10333. [CompletionReBuildENG]
  10334.         !MsgText        =       "SQL Server ("$(!ProductVersion)") is now rebuilt."
  10335.  
  10336. [CompletionNukedENG]
  10337.         !MsgText        =       "SQL Server ("$(!ProductVersion)") has been removed from this computer."$(!LF)$(!LF)"The files used by SETUP.EXE must be removed manually."
  10338.  
  10339. [CompletionClientNukedENG]
  10340.         !MsgText        =       "SQL Server Client Utilities ("$(!ProductVersion)") have been removed from this computer."$(!LF)$(!LF)
  10341.  
  10342. [CompletionNukedRemoteENG]
  10343.         !MsgText        =       "SQL Server ("$(!ProductVersion)") has been removed from \\"$(!ComputerName)$(!LF)$(!LF)"."
  10344.  
  10345. [CompletionLangInstENG]
  10346.         !MsgText        =       "The new language has been successfully added."
  10347.  
  10348. [CompletionOptionsENG]
  10349.         !MsgText        =       "The SQL Server options have been successfully updated."
  10350.  
  10351. [STR_CompletionSecurity]
  10352.         !MsgText        =       "The SQL Server security options have been successfully updated."$(!LF)$(!LF)+
  10353.                                 "The changes will become effective the next time SQL Server is started."
  10354.  
  10355. [FailedUserSetupQuitENG]
  10356.         !MsgText        =       "Setup has been terminated."$(!LF)$(!LF)
  10357.  
  10358. [FailedUserQuitENG]
  10359.         !AddlText       =       "Setup has been terminated."$(!LF)$(!LF)
  10360.  
  10361. [UserQuitMsgENG]
  10362.         !AddlText       =       "Setup has been terminated."$(!LF)$(!LF)
  10363.  
  10364. [CannotUpgradeENG]
  10365.         !MsgText        =       "SQL Server ("$(!ProductVersion)") cannot be upgraded because: "$(!LF)$(!LF)
  10366.  
  10367. [ChkUpgRepLocENG]
  10368.         !Addl95Text       =       "A detailed review of upgrade problems may be found in: "
  10369.  
  10370. [CheckUpgradeDlgENG]
  10371.         !MsgText        =       "SQL Server Setup detected the following non-critical issues: "$(!LF)$(!LF)
  10372.  
  10373. [SQLExecErrorENG]
  10374.         !AddlText       =       "An error occurred while executing a SQL statement:"
  10375.  
  10376. [UpgradeErrorENG]
  10377.         !MsgText        =       "The SQL Server upgrade could not be successfully completed."$(!LF)$(!LF)
  10378.  
  10379. [DupKeyErrorENG]
  10380.         !MsgText        =       "Setup could not copy the previous installation's SQL Server key."$(!LF)$(!LF)
  10381.  
  10382. [InstallErrorENG]
  10383.         !MsgText        =       "The SQL Server installation could not be successfully completed."$(!LF)$(!LF)
  10384.  
  10385. [NukeErrorENG]
  10386.         !MsgText        =       "SQL Server could not be successfully removed."$(!LF)$(!LF)
  10387.  
  10388. [SetSecErrorENG]
  10389.         !MsgText        =       "The SQL Server security options could not be successfully set."$(!LF)$(!LF)
  10390.  
  10391. [SCMErrorENG]
  10392.         !AddlText       =       "A Service Control Manager error occurred."
  10393.  
  10394. [SetupInitENG]
  10395.         !MsgText        =       "Setup initialization could not be successfully completed."$(!LF)$(!LF)
  10396.  
  10397. [NetInstallErrorENG]
  10398.         !MsgText        =       "The network could not be successfully installed."$(!LF)$(!LF)
  10399.  
  10400. [UtilInstallErrorENG]
  10401.         !MsgText        =       "The SQL Server utilities could not be successfully installed."$(!LF)$(!LF)
  10402.  
  10403. [LangErrorENG]
  10404.         !MsgText        =       "The language could not be successfully installed."$(!LF)$(!LF)
  10405.  
  10406. [ServerOptsErrorENG]
  10407.         !MsgText        =       "The server options could not be updated successfully."$(!LF)$(!LF)
  10408.  
  10409. [RebuildErrorENG]
  10410.         !MsgText        =       "The master database could not be successfully rebuilt."$(!LF)$(!LF)
  10411.  
  10412. [NetStartErrorENG]
  10413.         !AddlText       =       " The service could not be started. Please check the error/event log to determine the cause."
  10414.  
  10415. [NetStopErrorENG]
  10416.         !AddlText       =       " The service could not be stopped."
  10417.  
  10418. [NetworkDriveConnectErrorENG]
  10419.         !AddlText       =       "Setup could not connect to the remote "
  10420.  
  10421. [NetworkDriveConnectSQLInstENG]
  10422.         !AddlText       =       "SQL Server installation share - "
  10423.  
  10424. [NetworkDriveConnectNTInstENG]
  10425.         !AddlText       =       "Windows NT installation share - "
  10426.  
  10427. [NetworkDriveConnectDBInstENG]
  10428.         !AddlText       =       "master database share - "
  10429.  
  10430. [STR_Plenty]
  10431.         !AddlText       =       "Sufficient space"
  10432.  
  10433. [ProcessExecErrorENG]
  10434.         !AddlText       =       "could not be executed. Please check the relevant .OUT file."$(!LF)
  10435.  
  10436. [ProcessRetErrorENG]
  10437.         !AddlText       =       "An error was reported: "
  10438.  
  10439. [CannotCreateFileENG]
  10440.         !AddlText       =       "The CONFIG file could not be created."
  10441.  
  10442. [DiskFullENG]
  10443.         !AddlText       =       "There is insufficient disk space for the CONFIG file."
  10444.  
  10445. [DirCreateErrorENG]
  10446.         !AddlText       =       "The following directory could not be created: "
  10447.  
  10448. [SQLBadResultsENG]
  10449.         !AddlText       =       "Install verification failed because at least one SQL script did not install correctly. Please check the script .OUT files. The verification check failed with the following item not being found: "
  10450.  
  10451. [NoServerNameENG]
  10452.         !AddlText       =       "You must specify a Windows NT-based SQL Server."
  10453.  
  10454. [NoServerPathENG]
  10455.         !AddlText       =       "You must specify a SQL Server path."
  10456.  
  10457. [NoMasterPathENG]
  10458.         !AddlText       =       "You must specify a master database path."
  10459.  
  10460. [NoTCPIPSocketENG]
  10461.         !AddlText       =       "You must specify a TCP/IP socket number."
  10462.  
  10463. [MasterExistsENG]
  10464.         !YesNoQ         =       "The master database already exists in this path."$(!LF)"Are you sure you want to overwrite it?"
  10465.  
  10466. [TCPIPNotRunningENG]
  10467.         !AddlText       =       "The TCP/IP service is not currently running."$(!LF)"You cannot install this Net-Library if the TCP/IP service is not installed and started."
  10468.  
  10469. [STR_NWLinkNotRunning]
  10470.         !YesNoQ         =       "The NWLink service is not currently running."$(!LF)"Do you still want to select this Net-Library?"
  10471.  
  10472. [NoRemoteSpecENG]
  10473.         !AddlText       =       "You must specify a remote computer name."
  10474.  
  10475. [NoLoginToSQLServerENG]
  10476.         !AddlText       =       "Setup could not connect to the SQL Server."
  10477.  
  10478. [InstalledTagENG]
  10479.         !RebootType     =       "SQL Server ("$(!ProductVersion)") is now installed."
  10480.  
  10481. [UpgradedTagENG]
  10482.         !RebootType     =       "SQL Server ("$(!ProductVersion)") is now upgraded."
  10483.  
  10484. [UtilInstallTagENG]
  10485.         !RebootType     =       "SQL Server ("$(!ProductVersion)") utilities are now installed."
  10486.  
  10487. [STR_DLLRenameError]
  10488.         !AddlText       =       "Setup cannot rename "$(!OneOffFile)". Ensure that you are not running any other applications that use this file, and then restart setup."
  10489.  
  10490. [STR_SpacedComputerName]
  10491.         !AddlText       =       "The computer name "$(!ComputerName)" contains at least one whitespace character. The SQL Server computer name cannot contain whitespace characters, therefore you will need use a name without whitespace."
  10492.  
  10493. [STR_NonCriticalScriptFail]
  10494.         !AddlText       =       $(!LF)"At least one non-critical SQL script failed to install correctly. Please check the Install .OUT files."
  10495.  
  10496. [PasswordsDontMatchENG]
  10497.         !AddlText       =       $(!LF)"The password was not correctly confirmed. Please be sure that the confirmation password exactly matches the password."
  10498.  
  10499. [DeleteEventLogENG]
  10500.         !YesNoQ         =       "In order to disable event logging, the Application event log must be cleared with no backup created. If SQL Server is running it will be stopped and restarted. Do you wish to continue?"
  10501.  
  10502. [NoNetChangeIntSec]
  10503.         !AddlText       =       "You cannot change the network support options because your login security mode is set to 'Windows NT Integrated' in the Set Security Options dialog."$(!LF)$(!LF)+
  10504.          "If you need to support protocols other than named pipes and/or Multi-protocol, you must first change the security mode to 'Standard' or 'Mixed'."
  10505.  
  10506. [NoNetChangeDevVer]
  10507.         !AddlText       =       "You cannot change the network support options because you are using the SQL Server Desktop System, which only supports local named pipes connections."
  10508.  
  10509. [SetUserIDErrorENG]
  10510.         !AddlText       =       "The entered Login ID/Password failed verification. Please re-check your Login ID and Password."$(!LF)$(!LF)
  10511.  
  10512. [ODBCInstallFailENG]
  10513.         !AddlText       =       "ODBC could not be installed: "$(!ODBCError)", please install it by running the setup utility in the ODBC directory on the SQL Server CD."$(!LF)$(!LF)
  10514.  
  10515. [MustHavePipesENG]
  10516.         !AddlText       =       "The Named Pipes protocol cannot be turned off in a new install."$(LF)$(LF)
  10517.  
  10518. [TooFewSeatsENG]
  10519.         !AddlText       =       "The minimum number of users per Microsoft SQL Server is 1, please increase that number."$(LF)$(LF)
  10520.  
  10521. [OldSQLBeta3ENG]
  10522.         !MsgText        =       "Setup has detected an install of the March 1995 SQL Server Beta. "
  10523.         !AddlText       =       "To upgrade or perform a new install, follow the Release Note instructions provided with this release."$(LF)
  10524.  
  10525.  
  10526. [SMSConflictENG]
  10527.         !AddlText        =       "Setup has detected a version 1.0 of SMS, which will not operate with SQL Server ("$(!ProductVersion)")."
  10528.  
  10529. [WindowsNTENG]
  10530.         !WindowsBase    =       "Windows NT"
  10531.         !SQLServerBase  =       "SQL Server"
  10532.  
  10533. [Windows95ENG]
  10534.         !WindowsBase    =       "Windows 95"
  10535.         !SQLServerBase  =       "SQL Server Client Utilities"
  10536.  
  10537. [ReadOnlyAutoexecENG]
  10538.         !AddlText       =       "Your AUTOEXEC.BAT file was read-only, please update the path statement to include "$(!SQLPath)"\"$(!Binaries)";"$(!SQLPath)"\"$(!DLLs)"."
  10539.  
  10540. [DontDeleteRootENG]
  10541.         !AddlText       =       "Setup cannot delete files/directories from the root of your drive "$(!DefSQLPath)"."
  10542.  
  10543. [CantGetDevNoENG]
  10544.     !MsgText    =    "Setup cannot determine the next available device number, replication device creation failed!"
  10545.  
  10546. [InternationalSetup]
  10547.         !Locale         =       ""
  10548. [SetupInstFlags]
  10549.        ODBCInstall = "YES"
  10550.        SQLBooksInst = "YES"
  10551.        RISCInst = "YES"
  10552.        PPCInst = "YES"
  10553.  
  10554. [LocaleFile]
  10555.         1, common.loc,SIZE=2700
  10556.         1, server.loc,SIZE=130000
  10557.  
  10558. [BaseInstallExes]
  10559.         1, setup.exe,SIZE=365065
  10560.         1, setup.inf,SIZE=356463
  10561.         1, sqlsetup.hlp,SIZE=155276
  10562.         1, sqlsetup.dll,SIZE=153088
  10563.         1, splash.dll,SIZE=270000
  10564.         1, sqlservr.exe, SIZE=2414592
  10565.         1, sqlexec.exe, SIZE=52224
  10566.         1, sqlalrtr.exe, SIZE=13000
  10567.         1, xfragent.exe, SIZE=25000
  10568.         1, charset.exe,  SIZE=122368
  10569.         1, langinst.exe, SIZE=92160
  10570.         1, sqlctrs.pmc,  SIZE=1164
  10571.         1, console.exe,  SIZE=54272
  10572.         1, helpsql.hlp,  SIZE=192146
  10573.         1, sqlmgr.exe,  SIZE=101376
  10574.         1, chkupg.exe, SIZE=40960
  10575.         1, odbcping.exe, SIZE=54000
  10576.         1, sqlmaint.exe, SIZE=100000
  10577. [DOSInstallExes]
  10578.         1, dbnmp3.dll,   SIZE=10944
  10579.         1, dbmsspx3.dll, SIZE=21744
  10580.         1, dbmsvin3.dll, SIZE=18620
  10581.         1, dbmssoc3.dll, SIZE=10832
  10582.         1, dbmsrpc3.dll, SIZE=22792
  10583.         1, dbnmpipe.exe, SIZE=10115
  10584.         1, dbmsspx.exe,  SIZE=19473
  10585.         1, dbmsvine.exe, SIZE=30932
  10586.  
  10587. [BaseInstallDLLs]
  10588.         1, opends60.dll, SIZE=123392
  10589.         1, ssnmpn60.dll, SIZE=16384
  10590.         1, xpsql60.dll,  SIZE=15872
  10591.         1, sqlper60.dll,  SIZE=34304
  10592.         1, ssmsso60.dll, SIZE=23040
  10593.         1, sqlevn60.dll, SIZE=50688
  10594.         1, sqltl32.dll,  SIZE=439808,CHECKVERSION=*($(!SetupFileVersion), 1)^*($(!SetupFileVersion),2)
  10595.         1, sqlctr60.dll,  SIZE=35328
  10596.         1, evntct60.dll, SIZE=4608
  10597.         1, xplog60.dll,  SIZE=67584
  10598.         1, ssmssp60.dll, SIZE=34816
  10599.         1, dbmsspxn.dll, SIZE=23040,CHECKVERSION=*($(!SetupFileVersion), 1)^*($(!SetupFileVersion),2)
  10600.         1, dbmssocn.dll, SIZE=15360,CHECKVERSION=*($(!SetupFileVersion), 1)^*($(!SetupFileVersion),2)
  10601.         1, sqlmap60.dll,  SIZE=54272
  10602.         1, sqlsvc32.dll, SIZE=48662
  10603.         1, sqlgui32.dll, SIZE=430080
  10604.         1, sqlqry32.dll, SIZE=115712
  10605.         1, starcmon.dll, SIZE=185856
  10606. ;       1, sqlobj.dll,   SIZE=707072
  10607.         1, xpstar.dll,   SIZE=55296
  10608.         1, sqlexec.dll, SIZE=5632
  10609.         1, sqlole32.dll, SIZE=999424
  10610.         1, sqlole32.tlb, SIZE=148663
  10611.         1, sqlole.hlp,SIZE=110000
  10612. ;        1, odsole32.hlp, SIZE=100000
  10613.         1, odsole32.dll, SIZE=100000
  10614.         1, odsole32.tlb, SIZE=10000
  10615.         1, sqewstat.dll, SIZE=250000
  10616.         1, sqewexec.dll, SIZE=250000
  10617.         1, sqewrepl.dll, SIZE=250000
  10618.         1, sqewobj.dll, SIZE=250000
  10619.         1, sqewtips.dll, SIZE=250000
  10620.         1, sqewsys.dll, SIZE=250000
  10621.         1, sqewwiz.dll, SIZE=250000
  10622.         1, sqewnt.dll, SIZE=250000
  10623.         1, dbmsadsn.dll, SIZE=20922,CHECKVERSION=*($(!SetupFileVersion), 1)^*($(!SetupFileVersion),2)
  10624.         1, ssmsad60.dll, SIZE=23552,CHECKVERSION=*($(!SetupFileVersion), 1)^*($(!SetupFileVersion),2)
  10625. ;       1, dbmsdecn.dll, SIZE=13312,CHECKVERSION=*($(!SetupFileVersion), 1)^*($(!SetupFileVersion),2)
  10626. ;       1, ssmsde60.dll, SIZE=23552,CHECKVERSION=*($(!SetupFileVersion), 1)^*($(!SetupFileVersion),2)
  10627.         1, dbmsrpcn.dll, SIZE=22528,CHECKVERSION=*($(!SetupFileVersion), 1)^*($(!SetupFileVersion),2)
  10628.         1, ssmsrp60.dll, SIZE=27136,CHECKVERSION=*($(!SetupFileVersion), 1)^*($(!SetupFileVersion),2)
  10629.         1, sqlrepl.dll,  SIZE=61440
  10630.         1, cmdexec.dll,  SIZE=5120
  10631. ;       1, msvcrt20.dll, SIZE=243200,CHECKVERSION=*($(!MSVCFileVersion), 1)^*($(!MSVCFileVersion),2)
  10632.         1, msvcrt40.dll, SIZE=243200,CHECKVERSION=*($(!MSVCFileVersion), 1)^*($(!MSVCFileVersion),2)
  10633. ;       1, mfc30.dll,    SIZE=348160,CHECKVERSION=*($(!MFCFileVersion), 1)^*($(!MFCFileVersion),2)
  10634.         1, mfc40.dll,    SIZE=348160,CHECKVERSION=*($(!MFCFileVersion), 1)^*($(!MFCFileVersion),2)
  10635. ;        1, sqlole.reg, SIZE=26248
  10636.         1, msdtc.reg, SIZE=4196
  10637.         1, sqlsnmp.dll, !DECOMPRESS, SIZE=10000
  10638.         1, printdmp.exe, !DECOMPRES, SIZE=150000
  10639.  
  10640. [BaseInstallDLLDBGs]
  10641.         1, opends60.dbg,SIZE=1000000
  10642.  
  10643. [BaseInstallExeDBGs]
  10644.     1, sqlservr.dbg,SIZE=4000000
  10645.  
  10646. [MasterFiles]
  10647.         1, master.al@,SIZE=2000000,!DECOMPRESS
  10648.         1, master.da@,SIZE=4000000,!DECOMPRESS
  10649.  
  10650. [MasterAltFile]
  10651.         1, master.al@,SIZE=2000000,RENAME=master.dat
  10652.  
  10653. [MasterDefFile]
  10654.         1, master.da@,SIZE=4000000,RENAME=master.dat
  10655.  
  10656.  
  10657.  
  10658. [ClientDLLs]
  10659.         1, dbnmpntw.dll,SIZE=24064,CHECKVERSION=*($(!SetupFileVersion), 1)^*($(!SetupFileVersion),2)
  10660.         1, ntwdblib.dll,SIZE=364032,CHECKVERSION=*($(!SetupFileVersion), 1)^*($(!SetupFileVersion),2)
  10661.  
  10662. [ControlPanel]
  10663.         1, windbver.exe,SIZE=52224
  10664.  
  10665. [InstallExes]
  10666.         1, charset.exe, SIZE=122368
  10667.  
  10668. [InstallDLLs]
  10669.         1, opends60.dll,SIZE=123392
  10670.         1, ssnmpn60.dll,SIZE=16384
  10671.         1, sqlevn60.dll,SIZE=50688
  10672.         1, xpstar.dll, SIZE=55296
  10673.         1, msvcrt40.dll, SIZE=243200,CHECKVERSION=*($(!MSVCFileVersion), 1)^*($(!MSVCFileVersion),2)
  10674.         1, sqlsvc32.dll, SIZE=48662
  10675.  
  10676. [BaseInstall]
  10677.         1, dropall.sql, SIZE=20063
  10678.         1, upgrade1.sql,SIZE=35000
  10679.         1, checkobj.sql, SIZE=26000
  10680.         1, messages.sql,SIZE=126000
  10681.         1, u_tables.sql, SIZE=20000
  10682.         1, configur.sql,SIZE=20000
  10683.         1, procsyst.sql, SIZE=525000
  10684.         1, instrepl.sql,SIZE=210000
  10685.         1, unadmin.sql, SIZE=5593
  10686.         1, unobj.sql,SIZE=2241
  10687.         1, tempsp.sql,SIZE=746
  10688.         1, instpubs.sql, SIZE=23916
  10689.         1, instcat.sql,  SIZE=127928
  10690.         1, helpsql.sql,  SIZE=130370
  10691.         1, instlang.sql, SIZE=2551
  10692.         1, instsupl.sql, SIZE=4411
  10693.         1, instdist.sql, SIZE=58025
  10694.         1, sqlcommn.loc, SIZE=4314
  10695.         1, xpstar.sql, SIZE=4175
  10696.         1, sqlole60.sql, SIZE=12279
  10697.         1, sqlole42.sql, SIZE=13937
  10698.         1, instmsdb.sql, SIZE=54402
  10699.         1, servmsgs.sql, SIZE=67000
  10700.         1, admin60.sql, SIZE=127116
  10701.         1, object60.sql, SIZE=45270
  10702.         1, 5lakes.txt,   SIZE=7746
  10703.         1, algodata.txt, SIZE=1701
  10704.         1, binnet.txt,   SIZE=151
  10705.         1, gggg.txt,     SIZE=151
  10706.         1, lucerne.txt,  SIZE=151
  10707.         1, newmoon.txt,  SIZE=69476
  10708.         1, ramona.txt,   SIZE=151
  10709.         1, scootney.txt, SIZE=151
  10710.         1, 5lakes.bmp,   SIZE=6566
  10711.         1, algodata.bmp, SIZE=3018
  10712.         1, binnet.bmp,   SIZE=3502
  10713.         1, gggg.bmp,     SIZE=1750
  10714.         1, lucerne.bmp,  SIZE=3286
  10715.         1, newmoon.bmp,  SIZE=3466
  10716.         1, ramona.bmp,   SIZE=4410
  10717.         1, scootney.bmp, SIZE=5398
  10718.         1, pubtext.bat, SIZE=966
  10719.         1, pubimage.bat, SIZE=983
  10720.         1, readme.txt, SIZE=4096
  10721.         1, kb_msl.hlp, SIZE=29000
  10722.         1, WEB.SQL, !DECOMPRESS, SIZE=15926
  10723.         1, EARLY1.SQL, SIZE=1983
  10724.  
  10725. [Charset437]
  10726.         1, CP437BIN.437,SIZE=777
  10727.         1, DICTION.437,SIZE=8484
  10728.         1, NOACCENT.437,SIZE=8506
  10729.         1, NOCASE.437,SIZE=8350
  10730.         1, NOCASEPR.437,SIZE=9077
  10731.  
  10732. [Charset850]
  10733.         1, CP850BIN.850,SIZE=777
  10734.         1, DICTION.850,SIZE=8467
  10735.         1, NOACCENT.850,SIZE=8520
  10736.         1, NOCASE.850,SIZE=8438
  10737.         1, NOCASE34.850,SIZE=6080
  10738.         1, NOCASEPR.850,SIZE=9098
  10739.         1, ALTDICT.850,SIZE=8542
  10740.         1, ALTNOACC.850,SIZE=8471
  10741.         1, ALTNOCSP.850,SIZE=9348
  10742.         1, ALTNOCS.850,SIZE=9355
  10743.         1, SCANDICT.850,SIZE=8230
  10744.         1, SCANNOCP.850,SIZE=9133
  10745.         1, SCANNOCS.850,SIZE=9156
  10746.  
  10747. [CharsetISO]
  10748.         1, ISO_1BIN.ISO,SIZE=810
  10749.         1, DICTION.ISO,SIZE=8698
  10750.         1, NOACCENT.ISO,SIZE=8733
  10751.         1, NOCASE.ISO,SIZE=8625
  10752.         1, NOCASEPR.ISO,SIZE=9307
  10753.         1, DANONOCP.ISO,SIZE=8985
  10754.         1, ISLANOCP.ISO,SIZE=8943
  10755.         1, SVF1NOCP.ISO,SIZE=9090
  10756.         1, SVF2NOCP.ISO,SIZE=9091
  10757.  
  10758. [Charset1250]
  10759.         1, BINARY.250, !DECOMPRESS, SIZE=799
  10760.         1, DICTION.250, !DECOMPRESS, SIZE=7613
  10761.         1, NOCASE.250, !DECOMPRESS, SIZE=7606
  10762.         1, CSYDIC.250, !DECOMPRESS, SIZE=7659
  10763.         1, CSYNC.250, !DECOMPRESS, SIZE=7678
  10764.         1, HUNDIC.250, !DECOMPRESS, SIZE=7687
  10765.         1, HUNNC.250, !DECOMPRESS, SIZE=7706
  10766.         1, PLKDIC.250, !DECOMPRESS, SIZE=7789
  10767.         1, PLKNC.250, !DECOMPRESS, SIZE=7808
  10768.         1, ROMDIC.250, !DECOMPRESS, SIZE=7858
  10769.         1, ROMNC.250, !DECOMPRESS, SIZE=7877
  10770.         1, SHLDIC.250, !DECOMPRESS, SIZE=7676
  10771.         1, SHLNC.250, !DECOMPRESS, SIZE=7695
  10772.         1, SKYDIC.250, !DECOMPRESS, SIZE=7852
  10773.         1, SKYNC.250, !DECOMPRESS, SIZE=7870
  10774.         1, SLVDIC.250, !DECOMPRESS, SIZE=7864
  10775.         1, SLVNC.250, !DECOMPRESS, SIZE=7881
  10776.  
  10777. [Charset1251]
  10778.         1, BINARY.251, !DECOMPRESS, SIZE=799
  10779.         1, DICTION.251, !DECOMPRESS, SIZE=7613
  10780.         1, NOCASE.251, !DECOMPRESS, SIZE=7606
  10781.         1, UKRDIC.251, !DECOMPRESS, SIZE=8851
  10782.         1, UKRNC.251, !DECOMPRESS, SIZE=8870
  10783.  
  10784. [Charset1253]
  10785.         1, BINARY.253, !DECOMPRESS, SIZE=799
  10786.         1, DICTION.253, !DECOMPRESS, SIZE=7613
  10787.         1, NOCASE.253, !DECOMPRESS, SIZE=7606
  10788.         1, GRALTDCT.253, !DECOMPRESS, SIZE=10046
  10789.         1, GRMXTDCT.253, !DECOMPRESS, SIZE=11063
  10790.         1, GRNOACCE.253, !DECOMPRESS, SIZE=9952
  10791.  
  10792. [Charset1254]
  10793.         1, BINARY.254, !DECOMPRESS, SIZE=799
  10794.         1, DICTION.254, !DECOMPRESS, SIZE=7102
  10795.         1, NOCASE.254, !DECOMPRESS, SIZE=7098
  10796.  
  10797. [Charset1255]
  10798.         1, BINARY.255, !DECOMPRESS, SIZE=799
  10799.         1, DICTION.255, !DECOMPRESS, SIZE=8096
  10800.         1, NOCASE.255, !DECOMPRESS, SIZE=8259
  10801.  
  10802. [Charset1256]
  10803.         1, BINARY.256, !DECOMPRESS, SIZE=799
  10804.         1, DICTION.256, !DECOMPRESS, SIZE=7077
  10805.         1, NOCASE.256, !DECOMPRESS, SIZE=7755
  10806.  
  10807. [Charset1257]
  10808.         1, BINARY.257, !DECOMPRESS, SIZE=799
  10809.         1, DICTION.257, !DECOMPRESS, SIZE=7613
  10810.         1, NOCASE.257, !DECOMPRESS, SIZE=7606
  10811.         1, ETIDIC.257, !DECOMPRESS, SIZE=6969
  10812.         1, ETINC.257, !DECOMPRESS, SIZE=7011
  10813.         1, LTHDIC.257, !DECOMPRESS, SIZE=7010
  10814.         1, LTHNC.257, !DECOMPRESS, SIZE=7024
  10815.         1, LVIDIC.257, !DECOMPRESS, SIZE=7001
  10816.         1, LVINC.257, !DECOMPRESS, SIZE=7012
  10817.  
  10818. [Charset932]
  10819.         1, CP932BIN.932, !DECOMPRESS, SIZE=799
  10820.         1, CP932NLS.932, !DECOMPRESS, SIZE=7500
  10821.  
  10822. [Charset936]
  10823.         1, CP936BIN.936, !DECOMPRESS, SIZE=799
  10824.         1, CP936NLS.936, !DECOMPRESS, SIZE=7500
  10825.  
  10826. [Charset949]
  10827.         1, CP949BIN.949, !DECOMPRESS, SIZE=799
  10828.         1, CP949NLS.949, !DECOMPRESS, SIZE=7500
  10829.  
  10830. [Charset950]
  10831.         1, CP950BIN.950, !DECOMPRESS, SIZE=799
  10832.         1, CP950NLS.950, !DECOMPRESS, SIZE=7500
  10833.  
  10834. [Util1]
  10835.         1, BCP.exe, SIZE=90624
  10836.  
  10837. [Util2]
  10838.         1, isql.exe, SIZE=108032
  10839.         1, isqlw.exe, SIZE=117760
  10840.         1, isqlw.hlp, SIZE=65408
  10841.  
  10842. [Util3]
  10843.         1, sqlew.exe,SIZE=502784
  10844.  
  10845. [Util3Help]
  10846.         1, sqlew.hlp, SIZE=159735
  10847.  
  10848. [Util3DLL]
  10849.         1, sqlqry32.dll, SIZE=115712
  10850.         1, starcmon.dll, SIZE=185856
  10851. ;       1, sqlobj.dll,  SIZE=707072
  10852.         1, xpstar.dll,  SIZE=55296
  10853. ;        1, sqlole.reg, SIZE=26248
  10854.         1, sqewstat.dll, SIZE=250000
  10855.         1, sqewexec.dll, SIZE=250000
  10856.         1, sqewrepl.dll, SIZE=250000
  10857.         1, sqewobj.dll, SIZE=250000
  10858.         1, sqewsys.dll, SIZE=250000
  10859.         1, sqewwiz.dll, SIZE=250000
  10860.         1, sqewnt.dll, SIZE=250000
  10861.         1, sqewtips.dll, SIZE=250000
  10862.  
  10863. [Util3Samp]
  10864. ;       1, sqldmo.xls,SIZE=56320
  10865. ;       1, backup.frm,SIZE=6200
  10866. ;       1, cdinfo.frm,SIZE=3500
  10867. ;       1, cdinfo.frx,SIZE=100
  10868. ;       1, dbmdi.frm,SIZE=4000
  10869. ;       1, devmdi.frm,SIZE=3400
  10870. ;       1, dmodemo.frm,SIZE=24300
  10871. ;       1, dmodemo.frx,SIZE=1000
  10872. ;       1, dmodemo.mak,SIZE=1400
  10873. ;       1, fabout.frm,SIZE=3400
  10874. ;       1, fabout.frx,SIZE=1000
  10875. ;       1, fabout2.frm,SIZE=2900
  10876. ;       1, fabout2.frx,SIZE=1000
  10877. ;       1, fconnect.frm,SIZE=4300
  10878. ;       1, module1.bas,SIZE=250
  10879. ;       1, module2.bas,SIZE=150
  10880. ;       1, objmdi.frm,SIZE=4300
  10881. ;       1, sqlpdba.frm,SIZE=9900
  10882. ;       1, sqlpdba.frx,SIZE=3800
  10883. ;       1, sqlpdba.mak,SIZE=1600
  10884. ;       1, explore.bas,SIZE=19400
  10885. ;       1, explore.frm,SIZE=7200
  10886. ;       1, explore.mak,SIZE=400
  10887. ;       1, generic.frm,SIZE=400
  10888. ;       1, generic.mak,SIZE=400
  10889.  
  10890.  
  10891. [Util3Read]
  10892. ;        1, readme2.txt,RENAME=readme.txt,SIZE=600
  10893.  
  10894. [Util5]
  10895.         1, sqsecmgr.exe  SIZE=204800
  10896.         1, sqsecmgr.hlp, SIZE=60317
  10897.  
  10898. [Util6]
  10899.         1, READPIPE.exe  SIZE=46080
  10900.         1, makepipe.exe  SIZE=45056
  10901.  
  10902. [UtilDLLs]
  10903.         1, sqltl32.dll, SIZE=439808,CHECKVERSION=*($(!SetupFileVersion), 1)^*($(!SetupFileVersion),2)
  10904.         1, sqlgui32.dll, SIZE=430080
  10905.         1, sqlsvc32.dll, SIZE=49664
  10906.         1, sqlole32.dll, SIZE=999424
  10907.         1, sqlole32.tlb, SIZE=148663
  10908.         1, dbmsspxn.dll,SIZE=23040,CHECKVERSION=*($(!SetupFileVersion), 1)^*($(!SetupFileVersion),2)
  10909.         1, dbmssocn.dll,SIZE=15360,CHECKVERSION=*($(!SetupFileVersion), 1)^*($(!SetupFileVersion),2)
  10910.         1, dbmsadsn.dll,SIZE=20992,CHECKVERSION=*($(!SetupFileVersion), 1)^*($(!SetupFileVersion),2)
  10911. ;       1, dbmsdecn.dll,SIZE=13312,CHECKVERSION=*($(!SetupFileVersion), 1)^*($(!SetupFileVersion),2)
  10912.         1, dbmsrpcn.dll,SIZE=22528,CHECKVERSION=*($(!SetupFileVersion), 1)^*($(!SetupFileVersion),2)
  10913.         1, msvcrt40.dll, SIZE=243200,CHECKVERSION=*($(!MSVCFileVersion), 1)^*($(!MSVCFileVersion),2)
  10914.         1, mfc40.dll,    SIZE=348160,CHECKVERSION=*($(!MFCFileVersion), 1)^*($(!MFCFileVersion),2)
  10915. ;       1, mfc30.dll,    SIZE=348160,CHECKVERSION=*($(!MFCFileVersion), 1)^*($(!MFCFileVersion),2)
  10916.         1, sqlole.hlp,SIZE=110000
  10917.  
  10918. [UtilHelp]
  10919.         1, helpsql.hlp,  SIZE=192146
  10920.  
  10921. [ODBC1]
  10922.         1,12520437.cpx, SIZE=32552
  10923.         1,12520850.cpx, SIZE=32552
  10924.         1,_bootstp.exe, SIZE=32552
  10925.         1,_mssetup.ex_, SIZE=32552
  10926.         1,ctl3d32.dll, SIZE=32552
  10927.         1,dbnmpntw.dll, SIZE=32552
  10928.         1,drvssrvr.hlp, SIZE=32552
  10929.         1,ds16gt.dll, SIZE=32552
  10930.         1,ds32gt.dll, SIZE=32552
  10931. ;        1,mfc30.dll, SIZE=32552,CHECKVERSION=*($(!SetupFileVersion), 1)^*($(!SetupFileVersion),2)
  10932.         1,mfc40.dll, SIZE=32552,CHECKVERSION=*($(!SetupFileVersion), 1)^*($(!SetupFileVersion),2)
  10933.         1,mscpxl32.dll, SIZE=32552
  10934.         1, msvcrt40.dll, SIZE=243200,CHECKVERSION=*($(!MSVCFileVersion), 1)^*($(!MSVCFileVersion),2)
  10935.         1,remserve.inf, RENAME=odbc.inf,SIZE=32552
  10936.         1,odbc16gt.dll, SIZE=32552
  10937.         1,odbc32.dll, SIZE=32552
  10938.         1,odbc32gt.dll, SIZE=32552
  10939.         1,odbccp32.dll, SIZE=32552
  10940.         1,odbccr32.dll, SIZE=32552
  10941.         1,odbcint.dll, SIZE=32300
  10942.         1,odbcinst.hlp, SIZE=32552
  10943.         1,odbcst32.exe, SIZE=32552
  10944.         1,setup.exe, SIZE=32552
  10945.         1,setup.lst, SIZE=32552
  10946.         1,sqlsrv32.dll, SIZE=32552
  10947.         1,odbcinst.cnt, SIZE=500
  10948. ;        1,odbccp32.cpl, SIZE=32552
  10949.  
  10950. [ODBCRem]
  10951.         1,instodbc.dll,SIZE=5120
  10952.  
  10953. [ODBCInstalled]
  10954.         1,12520437.cpx, SIZE=32552
  10955.         1,12520850.cpx, SIZE=32552
  10956.         1,drvssrvr.hlp, SIZE=32552
  10957.         1,ds16gt.dll, SIZE=32552
  10958.         1,ds32gt.dll, SIZE=32552
  10959.         1,mfc40.dll, SIZE=32552,CHECKVERSION=*($(!SetupFileVersion), 1)^*($(!SetupFileVersion),2)
  10960.         1,mscpxl32.dll, SIZE=32552
  10961.         1, msvcrt40.dll, SIZE=243200,CHECKVERSION=*($(!MSVCFileVersion), 1)^*($(!MSVCFileVersion),2)
  10962.         1,odbc16gt.dll, SIZE=32552
  10963.         1,odbc32.dll, SIZE=32552
  10964.         1,odbc32gt.dll, SIZE=32552
  10965.         1,odbccp32.dll, SIZE=32552
  10966.         1,odbccr32.dll, SIZE=32552
  10967.         1,odbcint.dll, SIZE=32300
  10968.         1,odbcinst.hlp, SIZE=32552
  10969.         1,odbcst32.exe, SIZE=32552
  10970.         1,sqlsrv32.dll, SIZE=32552
  10971.         1,odbcinst.cnt, SIZE=500
  10972. ;        1,odbccp32.cpl, SIZE=32552
  10973.  
  10974. [SQLBooks1]
  10975.         1,HELP.HLP, SIZE=136849
  10976.         1,INFOVIEW.EXE, SIZE=922112
  10977.  
  10978. [SQLBooks2]
  10979.         1,SQLBOOKS.ICO, SIZE=766
  10980.  
  10981. [SQLBooks3]
  10982.         1,SQLBOOKS.IDX, SIZE=185000
  10983.         1,SQLBOOKS.AUX, SIZE=424000
  10984.         1,SQLBOOKS.KWD, SIZE=8192
  10985.         1,SQLBOOKS.CAC, SIZE=4000000
  10986.         1,SQLBOOKS.MVB, SIZE=8700000
  10987.  
  10988. [NewRDR]
  10989.         1,rdr.sys,SIZE=437456
  10990.  
  10991. [NewRPC]
  10992.         1,rpclts3.dll,SIZE=25600
  10993.         1,rpclts6.dll,SIZE=27136
  10994.  
  10995. [ReplScript]
  10996. ;        1,dbrepl.sql,SIZE=3557
  10997.  
  10998. [License]
  10999. ;       1,liccpa.cpl,SIZE=37136
  11000. ;       1,liccpa.hlp,SIZE=30000
  11001.  
  11002. [SNMP]
  11003.     1, MSSQL.MIB, !DECOMPRESS, SIZE=27029
  11004.  
  11005. [SQLTraceServer]
  11006.     1, SQLTRACE.DLL, !DECOMPRESS, SIZE=40000
  11007.  
  11008. [SQLTraceClient]
  11009.     1, SQLTRACE.EXE, !DECOMPRESS, SIZE=70000
  11010.     1, SQLTRACE.MAP, !DECOMPRESS, SIZE=10000
  11011.         1, SQLTRACE.HLP, !DECOMPRESS, SIZE=100000
  11012.  
  11013. [WebWriter]
  11014.     1, MSSQLWPW.EXE, !DECOMPRESS, SIZE=90112
  11015.  
  11016. [RegSvr32]
  11017.     1, REGSVR32.EXE,!DECOMPRESS,SIZE=24064
  11018.