Comment: Comment: M M SSSSSS IIIIII Comment: MM MM SS II InstallAware 5 for Windows Installer Comment: M M M M SSSSSS II Copyright(c) 1996-2006 InstallAware Software Corporation Comment: M M M SS II All rights reserved Comment: M M SSSSSS IIIIII Comment: Comment: Project Name: Best Authority Setup Comment: Description: InstallAWARE Installation Script Comment: Comments: Win32 Application Template Script [DEFINE REGION: Check Application Requirements] Get System Setting 800x600 Resolution into CHECKSYSTEM if Variable CHECKSYSTEM not Equals TRUE MessageBox: $TITLE$ Setup Error, This product requires at least 800x600 Resolution.$NEWLINE$$NEWLINE$Setup cannot continue. Terminate Installation end Get System Setting Administrator Rights into CHECKSYSTEM if Variable CHECKSYSTEM not Equals TRUE MessageBox: $TITLE$ Setup Error, This product requires at least Administrator Privileges.$NEWLINE$$NEWLINE$Setup cannot continue. Terminate Installation end Get System Setting Windows 2000 into CHECKSYSTEM if Variable CHECKSYSTEM not Equals TRUE MessageBox: $TITLE$ Setup Error, This product requires at least Windows 2000.$NEWLINE$$NEWLINE$Setup cannot continue. Terminate Installation end <> [DEFINE REGION: Define Setup Globals] Comment: Define Setup Components Define Component: Best Authority Application Define Component: Training Documents Comment: Initialize Setup Globals Get System Setting Windows NT Kernel (NT4, 2000, XP, 2003) into ISNT Get Folder Location System->Program Files Directory into PROGRAMFILES Get Common Folder Location System->Program Files Directory into COMMONFILES Get Common Folder Location Start Menu->Programs Group into SHORTCUTFILESALL Get Folder Location Start Menu->Programs Group into SHORTCUTFILES if Variable SHORTCUTFILESALL Equals Set Variable SHORTCUTFILESALL to $SHORTCUTFILES$ end Get Folder Location System->Desktop Directory into DESKTOPDIR Get Folder Location System->Windows Directory into WINDIR Get Folder Location System->System Directory into WINSYSDIR Get Folder Location Taskbar->Quick Launch Directory into QUICKLAUNCHDIR Get Folder Location WWW->WWWRoot into WWWROOTDIR Comment: Path for optional co-located License.ini & BAAdmin.ini Comment: This info will be passed to BAStartup.exe, later if Variable SFXPATH Equals Set Variable COLOPATH to $EXEDIR$ else Set Variable COLOPATH to $SFXPATH$ end Load Feature Selections from file $COLOPATH$\SetupChoices.txt <> [DEFINE REGION: Check/Install Application Pre-Requisites] [DEFINE REGION: Check Application Pre-Requisites] Comment: Check setup pre-requisites Set Variable PREREQ to FALSE Set Variable PRELIST to Set Variable ASKLOCATION to TRUE Set Variable TARGETDIR to $PROGRAMFILES$\$COMPANY$\$TITLE$ [compiler if Variable BUILDMODE not Equals PATCH] if Variable NEEDSUPGRADE Equals TRUE Read Registry Key HKLM\SOFTWARE\Levit & James, Inc\Best Authority\\InstallPath into TARGETDIR Read Registry Key HKLM\SOFTWARE\Levit & James, Inc\Best Authority\\InstalledVersion into PRIORVERSION Comment: MessageBox: TargetDir from InstallPath Key, >$TARGETDIR$< if Variable TARGETDIR not Equals Set Variable ASKLOCATION to FALSE end Set Variable PREREQ to TRUE Set Variable PRELIST to $PRELIST$$NEWLINE$Upgrade from previously installed version $PRIORVERSION$ end Include Script: BAcheckvb6 Include Script: checkmsi20 [compiler end] <> [DEFINE REGION: Install Application Pre-Requisites] Comment: Install setup pre-requisites if Variable PREREQ not Equals FALSE if Variable PRELIST not Equals Comment: Unlike sample script, PRELIST does NOT include prior version uninstall Display Dialog: prereq, wait for dialog to return (modal) if Variable WIZARD Equals CANCEL Terminate Installation end end Display Dialog: progressprereq, use as progress dialog (non-modal) [compiler if Variable BUILDMODE not Equals PATCH] if Variable NEEDSUPGRADE Equals TRUE Set Variable REMOVEOLD to Set Variable ERROROLD to Set Variable MAINTENANCE to FALSE end [DEFINE WEB MEDIA Microsoft Visual Basic Virtual Machine 6.0 with Service Pack 6] Include Script: setupvb6 [DEFINE WEB MEDIA Microsoft Windows Installer 2.0] Include Script: setupmsi20 [compiler end] Hide Dialog end <> <> [DEFINE REGION: Setup User Interview] if Variable MAINTENANCE Equals TRUE GoTo Label: Maintenance else [compiler if Variable BUILDMODE not Equals PATCH] Set Variable STARTMENU to $TITLE$ [compiler end] end label: Welcome Dialog Comment: Display Dialog: welcome, wait for dialog to return (modal) if Variable WIZARD Equals CANCEL GoTo Label: Main Install end [compiler if Variable BUILDMODE not Equals PATCH] label: License Check Display Dialog: licensecheck, wait for dialog to return (modal) if Variable WIZARD Equals BACK GoTo Label: Welcome Dialog else if Variable WIZARD Equals CANCEL GoTo Label: Main Install end end label: ReadMe Information Display Dialog: readme (if variable REMOVE is FALSE), wait for dialog to return (modal) if Variable WIZARD Equals BACK GoTo Label: License Check else if Variable WIZARD Equals CANCEL GoTo Label: Main Install end end label: User Registration Comment: Display Dialog: registration, wait for dialog to return (modal) if Variable WIZARD Equals BACK GoTo Label: ReadMe Information else if Variable WIZARD Equals CANCEL GoTo Label: Main Install end end label: Setup Type Display Dialog: setuptype, wait for dialog to return (modal) if Variable WIZARD Equals BACK GoTo Label: User Registration else if Variable WIZARD Equals CANCEL GoTo Label: Main Install end end Comment: TO-DO: Customize your minimum setup here if Variable MINIMUM Equals TRUE Deselect Component: Training Documents else if Variable COMPLETE Equals TRUE Select Component: Best Authority Application Select Component: Training Documents end end label: Custom Setup Display Dialog: componentstree (if variable PERSONALIZED is TRUE), wait for dialog to return (modal) if Variable WIZARD Equals BACK GoTo Label: Setup Type else if Variable WIZARD Equals CANCEL GoTo Label: Main Install end end label: Destination Directory if Variable ASKLOCATION Equals TRUE Display Dialog: destination, wait for dialog to return (modal) end if Variable WIZARD Equals BACK GoTo Label: Custom Setup else if Variable WIZARD Equals CANCEL GoTo Label: Main Install end end label: Start Menu Display Dialog: startmenu, wait for dialog to return (modal) if Variable WIZARD Equals BACK GoTo Label: Destination Directory else if Variable WIZARD Equals CANCEL GoTo Label: Main Install end end [compiler end] label: Start Installation Set Variable ACTION to install Comment: Display Dialog: startinstallation, wait for dialog to return (modal) if Variable WIZARD Equals BACK [compiler if Variable BUILDMODE not Equals PATCH] GoTo Label: Start Menu [compiler else] GoTo Label: Welcome Dialog [compiler end] else GoTo Label: Main Install end label: Maintenance Comment: Maintenance Install/Uninstall Set Variable MODIFY to FALSE Set Variable REPAIR to FALSE Set Variable REMOVE to TRUE Display Dialog: maintenance, wait for dialog to return (modal) Comment: Display Dialog: readme, wait for dialog to return (modal) if Variable WIZARD Equals BACK [compiler if Variable BUILDMODE not Equals PATCH] GoTo Label: Start Menu [compiler else] GoTo Label: Welcome Dialog [compiler end] else if Variable WIZARD Equals CANCEL GoTo Label: Main Install end end label: Maintenance Components Comment: Display Dialog: componentstree (if variable MODIFY is TRUE), wait for dialog to return (modal) if Variable WIZARD Equals BACK GoTo Label: Maintenance else if Variable WIZARD Equals CANCEL GoTo Label: Main Install end end label: Maintenance StartInstallation Set Variable ACTION to uninstall if Variable REPAIR Equals TRUE Set Variable ACTION to repair end if Variable REMOVE Equals TRUE Set Variable ACTION to uninstall end Display Dialog: startinstallation, wait for dialog to return (modal) if Variable WIZARD Equals BACK GoTo Label: Maintenance Components else if Variable WIZARD Equals CANCEL GoTo Label: Main Install end end <> [DEFINE REGION: Process (Un)Installation] label: Main Install Comment: Exit Setup if Wizard Loop cancelled if Variable WIZARD Equals CANCEL Terminate Installation end Comment: Prepare to install Set Variable SUCCESS to Set Variable LASTERROR to if Variable ALLUSERS Equals TRUE Set Variable SHORTCUTFOLDER to $SHORTCUTFILESALL$\$STARTMENU$ Set Variable TEMPLATELOCATIONFLAG to /m else Set Variable SHORTCUTFOLDER to $SHORTCUTFILES$\$STARTMENU$ Set Variable TEMPLATELOCATIONFLAG to /u end Display Dialog: progress, use as progress dialog (non-modal) Comment: Modify Target System [DEFINE REGION: Perform Uninstallation] if Variable REMOVE Equals TRUE Comment: Uninstall product Comment: TO-DO: Insert any additional uninstall commands here Run Program $TARGETDIR$\BAStartup.exe /t=BestAuth.dot /r (WAIT) Set Variable PROGRESSTEXT to UnInstalling $TITLE$ Apply Uninstall (get result into variable SUCCESS) Set Variable PROGRESS to 100 else <> [DEFINE REGION: Perform First Time or Maintenance Installation] if Variable NEEDSUPGRADE Equals TRUE Set Variable PROGRESSTEXT to Removing Prior Version of $TITLE$ Install/Remove MSI Package $PRODUCTCODE$[REMOVE=ALL] (get result into variable REMOVEOLD) if Variable REMOVEOLD Equals ERROR MessageBox: $TITLE$ Setup, Unable to uninstall old version of $TITLE$. Please uninstall it yourself using Control Panel Add-Remove Programs before attempting to install this product.$NEWLINE$$NEWLINE$$ERROROLD$ Terminate Installation end if Variable REMOVEOLD Equals REBOOT MessageBox: $TITLE$ Setup, Your computer needs to be restarted before $TITLE$ Setup can continue.$NEWLINE$$NEWLINE$Please save your work in all running programs and click OK to restart your computer. Setup will resume once your computer restarts.$NEWLINE$$NEWLINE$If you click CANCEL, setup will exit. You will have to run setup again at a later time to install $TITLE$. if Variable REBOOTNOW Equals OK Reboot Computer and Resume Setup else Terminate Installation end end end Set Variable PROGRESSTEXT to Installing $TITLE$ Comment: Delete Registry Values associated with BA before Version 1.0.123 Delete Registry KEY HKCU\Software\VB and VBA Program Settings\Best Authority\*.* Comment: Install/Re-Install product Create Shortcut $SHORTCUTFOLDER$\Uninstall Best Authority Setup to $UNINSTALLLINK$ [OFFLINE CONTENT] Install Files P:\BestAuth\Current\AppFiles\Root FEJ\AuthorMtce.exe to $TARGETDIR$, include subfolders Install Files P:\BestAuth\Current\AppFiles\Root FEJ\BADictionary.bacd to $TARGETDIR$, include subfolders Install Files P:\BestAuth\Current\AppFiles\Root FEJ\BADictionary_Intl.bacd to $TARGETDIR$, include subfolders Install Files P:\BestAuth\Current\AppFiles\Root FEJ\BAOverlayLJ.bald to $TARGETDIR$, include subfolders Install Files P:\BestAuth\Current\AppFiles\Root FEJ\BAParser.dll to $TARGETDIR$, include subfolders Install Files P:\BestAuth\Current\AppFiles\Root FEJ\EULA.doc to $TARGETDIR$ Install Files P:\BestAuth\Current\AppFiles\Root FEJ\OverlayMtce.exe to $TARGETDIR$, include subfolders Install Files P:\BestAuth\Current\AppFiles\Root FEJ\OverlayMtceApplet.dll to $TARGETDIR$, include subfolders Install Files P:\BestAuth\Current\AppFiles\Root JWS\BAAdminGuide.chm to $TARGETDIR$ Install Files P:\BestAuth\Current\AppFiles\Root JWS\BAAdminGuide.doc to $TARGETDIR$ Install Files P:\BestAuth\Current\AppFiles\Root JWS\BAAdminGuide.pdf to $TARGETDIR$ Install Files P:\BestAuth\Current\AppFiles\Root JWS\BAUserGuide.chm to $TARGETDIR$ Install Files P:\BestAuth\Current\AppFiles\Root JWS\BAUserGuide.doc to $TARGETDIR$ Install Files P:\BestAuth\Current\AppFiles\Root JWS\BAUserGuide.pdf to $TARGETDIR$ Create Shortcut $SHORTCUTFOLDER$\BA User Guide (pdf) to $TARGETDIR$\BAUserGuide.pdf Install Files P:\BestAuth\Current\AppFiles\Root KDP\BAClasses.ini to $TARGETDIR$ Install Files P:\BestAuth\Current\AppFiles\Root KDP\BAMain.dll to $TARGETDIR$, include subfolders Install Files P:\BestAuth\Current\AppFiles\Root KDP\BAStartup.exe to $TARGETDIR$, include subfolders Install Files P:\BestAuth\Current\AppFiles\Root KDP\BestAuth.dot to $TARGETDIR$, include subfolders Install Files P:\BestAuth\Current\AppFiles\Root KDP\Read Me.doc to $TARGETDIR$ Install Files P:\BestAuth\Current\AppFiles\Root KDP\Release Notes.doc to $TARGETDIR$ Install Files P:\BestAuth\Current\AppFiles\Root KDP\TipOfTheDay.txt to $TARGETDIR$ Install Files P:\BestAuth\Current\AppFiles\Root NJKA\BARichEdit.ocx to $TARGETDIR$, include subfolders Install Files P:\BestAuth\Current\AppFiles\Root NJKA\FSHooks.dll to $TARGETDIR$, include subfolders Install Files P:\BestAuth\Current\AppFiles\Root NJKA\LJDialogManager.dll to $TARGETDIR$, include subfolders Install Files P:\BestAuth\Current\AppFiles\Sample Master Files\Shared\Schemes\*.* to $TARGETDIR$\Sample Master Files\Shared\Schemes, include subfolders Install Files P:\BestAuth\Current\AppFiles\Sample Master Files\Shared\Scheme Tester Documents\*.* to $TARGETDIR$\Sample Master Files\Shared\Scheme Tester Documents, include subfolders Install Files P:\BestAuth\Current\AppFiles\Sample Master Files\BestAuth.INI to $TARGETDIR$\Sample Master Files Install Files P:\BestAuth\Current\AppFiles\Sample Master Files\Shared\BAAuthors.baau to $TARGETDIR$\Sample Master Files\Shared Install Files P:\BestAuth\Current\AppFiles\Sample Master Files\Shared\BestAuthStyles.dot to $TARGETDIR$\Sample Master Files\Shared Install Files P:\BestAuth\Current\AppFiles\Sample Master Files\Shared\Dictionaries\AutoLoadEveryone.baod to $TARGETDIR$\Sample Master Files\Shared\Dictionaries Install Files P:\BestAuth\Current\AppFiles\Support\AutoLoadPersonal.baod to $TARGETDIR$\Support Install Files P:\BestAuth\Current\AppFiles\System Files\ComCT332.ocx to $WINSYSDIR$ (Shared, Never Overwrite) Install Files P:\BestAuth\Current\AppFiles\System Files\ComDlg32.ocx to $WINSYSDIR$ (Shared, Never Overwrite) Install Files P:\BestAuth\Current\AppFiles\System Files\MSComCt2.ocx to $WINSYSDIR$ (Shared, Never Overwrite) Install Files P:\BestAuth\Current\AppFiles\System Files\TabCtl32.ocx to $WINSYSDIR$ (Shared, Never Overwrite) Install Files P:\BestAuth\Current\AppFiles\System Files\RichEd32.dll to $WINSYSDIR$ (Shared, Never Overwrite) Install Files P:\BestAuth\Current\AppFiles\System Files\RichTx32.ocx to $WINSYSDIR$ (Shared, Never Overwrite) Install Files P:\BestAuth\Current\AppFiles\System Files\Redemption.dll to $WINSYSDIR$ (Shared) Install Files P:\BestAuth\Current\AppFiles\System Files\tdbgpp8.dll to $WINSYSDIR$ (Shared) Install Files P:\BestAuth\Current\AppFiles\System Files\tdbg8.ocx to $WINSYSDIR$ (Shared) Install Files P:\BestAuth\Current\AppFiles\System Files\xadb8.ocx to $WINSYSDIR$ (Shared) Comment: Never overwrite BAAdmin.ini Comment: Note that this file may be overwritten later by BAStartup.exe Install Files P:\BestAuth\Current\AppFiles\Root KDP\BAAdmin.ini to $TARGETDIR$ (Never Overwrite), include subfolders Write Registry Key HKLM\SOFTWARE\Levit & James, Inc\Best Authority\\InstallPath, $TARGETDIR$ Write Registry Key HKLM\SOFTWARE\Levit & James, Inc\Best Authority\\InstalledVersion, $VERSION$ Install Files P:\BestAuth\Current\AppFiles\Root JWS\BAQuickRef.doc to $TARGETDIR$ [DEFINE WEB MEDIA Training Documents] Get Component Training Documents Selection State into Variable SELECTED if Variable SELECTED Equals TRUE Install Files P:\BestAuth\Current\AppFiles\Training Documents\*.* to $TARGETDIR$\Training Documents, include subfolders end [DEFINE WEB MEDIA Best Authority Application] Get Component Best Authority Application Selection State into Variable SELECTED if Variable SELECTED Equals TRUE end Comment: TO-DO: Insert any additional install commands here Save Feature Selections into file $TARGETDIR$\SetupChoices.txt [compiler if Variable BUILDMODE Equals PATCH] Apply Patch (get result into variable SUCCESS) [compiler else] if Variable ADVERTISE Equals TRUE Apply Advertised (get result into variable SUCCESS) else Apply Install (get result into variable SUCCESS) if Variable SUCCESS not Equals ERROR if Variable SUCCESS not Equals CANCEL Comment: This step will copy BestAuth.dot to Word's startup folder Comment: and will also look for co-located License.ini and BAAdmin.ini, and copy them to TARGETDIR Comment: MessageBox: ColoPath, $COLOPATH$ Run Program $TARGETDIR$\BAStartup.exe $TEMPLATELOCATIONFLAG$ /t=BestAuth.dot /c="$COLOPATH$" (WAIT) end end end [compiler end] Set Variable PROGRESS to 100 end <> <> [DEFINE REGION: Finish Setup] Comment: End of Installation Hide Dialog Display Dialog: finish, wait for dialog to return (modal) if Variable SILENT Equals FALSE if Variable REBOOTCOMPUTER Equals TRUE if Variable SUCCESS Equals REBOOT Reboot Computer end end if Variable RUNAPP Equals TRUE if Variable REMOVE Equals FALSE if Variable SUCCESS Equals COMPLETE Comment: TO-DO: Insert command that starts your application here end end end end <>