;domestic regular install logic
; switch01 = aust
; switch02 = can
; switch03 = euro
; switch04 = latinam
; switch05 = uk
; switch06 = us
; switch07 = custom install
; switch09 = IsACTResVaild
; switch10 = net install
; switch14 = is actwin2.exe selected
; switch15 = common data files
; switch41 = aust data files
; switch42 = can data files
; switch43 = euro data files
; switch44 = latin data files
; switch45 = uk data files
; switch46 = us data files
; switch50 = latin/euro common data files
; switch69 = wants to overwrite data files
; switch81 = aust default.des
; switch82 = can default.des
; switch83 = euro default.des
; switch84 = latin default.des
; switch85 = uk default.des
; switch86 = us default.des

[InstallVersion]                
3.3

[CompressionChars]
LZW = "8"
ZIP = "9"

[process]
Delete(wayin)
backup(custdll)
switch30=IsVideo(1280)       
#if(switch30)
   Bitmaps(pix2)
#else
   Bitmaps(pix)
#endif
;CallProc(DoCSDLL)
switch35=VersionSearch(application)
switch10=FALSE  ;not net install
switch11=TRUE  
switch16=Exists(MailIni)

GetPrevVerSize()
AllowIntlChars()
SetActiveCopy(Arccopy, install.inf)

#if(switch35)
	TargetDrive()
#else
	PathBrowse(WhereIsACT)
#endif

CallProc(IsActresValid)

#if(switch09)
CallProc(IsActRunning)

ResetTarget(ActMailInBox)					;// Tell the custom dll where ACT!mail messages are to delete
CallProc(DoPassword)

#if(switch13)
MessageBox(ActIsRunning)
Exit
#endif

CallProc(IsNetTarget)

switch92=Exists(aauexe)
switch93=Exists(aauhlp)


ResetTarget(Filters)
ResetTarget(Layouts)
ResetTarget(Mail)
ResetTarget(Printout)
MakeFilesReadWrite(ExeOnly)
MakeFilesReadWrite(DLLONLY)
MakeFilesReadWrite(FiltersOnly)
MakeFilesReadWrite(LayoutsOnly)
MakeFilesReadWrite(MailOnly)
MakeFilesReadWrite(PrintoutOnly)

#ifnot(switch17)
	ResetTarget(IniFiles)
	Delete(ActMailFiles)
#endif

#if(switch92)
	switch96=TRUE						;// If TRUE then we will remove the icon
	switch95=VerifyIni(IsCPToolsShell)
	
	#if(switch95)
		switch96=FALSE
	#endif

	#if(switch96)
		CallProc(KillAAUItem)
	#endif

	Delete(aauexe)
#endif

#if(switch93)
	Delete(aauhlp)
#endif

#if(switch10)
	switch11=FALSE
	NetAdminInstall
#endif

switch19=Exists(NetFiles)

#if(switch19)
	switch11=FALSE ;install netfiles
	NetAdminInstall
#endif
	
DisableUtils()
backup(pipeline)
CreateDirectory(RemoteDIR)
CreateDirectory(RemoteInDIR)
CreateDirectory(RemoteOutDIR)
CreateDirectory(RemoteElrDIR)
CreateDirectory(MailDIR)
CreateDirectory(DocsDIR)

Copy()

CreateDirectory(DataBaseSync)

switch61=Exists(newprint)
#if(switch61)
	Delete(PrintoutFiles)
#endif

#if(switch10)
	Backup(WinDlls)
#endif

#if(switch19)
	Backup(WinDlls)
#endif
	
CreateDirectory(Docs)

ResetTarget(IniFiles)
UpdateIni(ACTMAIL1)
UpdateIni(ACTMAIL2)
UpdateIni(ACTMAIL3)
UpdateIni(ACTMAIL4)
UpdateIni(ACTWIN1)

switch74=Exists(Actwin2Ini)

#if(switch74)
	DelFromIni(RemoveOldExt)
#endif

#ifnot(switch01)
	UpdateIni(WinIniAust)
#endif

#ifnot(switch02)
	UpdateIni(WinIniEuro)
#endif

#ifnot(switch03)
	UpdateIni(WinIniCan)
#endif

#ifnot(switch04)
	UpdateIni(WinIniLatin)
#endif

#ifnot(switch05)
	UpdateIni(WinIniUk)
#endif

#ifnot(switch06)
	UpdateIni(WinIniUs)
#endif


EnableUtils()
CreateDirectory(BcaseDIR)
CreateDirectory(OutboxDIR)
CreateDirectory(QueryDIR)
CreateDirectory(DeferredDIR)
CallProc(CreateConfigFile)
CallProc(FirstLanpack)
Groups()

Backup(SaveEm)
UpdateIni(AddExts)
CallProc(DoRegDLL)

	 		
MessageBox(Thanks)

#else
	MessageBox(ActNotInstalled)
#endif

Delete(CSDLL)
ResetTarget(Filters)
ResetTarget(Layouts)
ResetTarget(Mail)
ResetTarget(Printout)
MakeFilesReadonly(ExeOnly)
MakeFilesReadonly(DLLONLY)
MakeFilesReadOnly(FiltersOnly)
MakeFilesReadOnly(LayoutsOnly)
MakeFilesReadOnly(MailOnly)
MakeFilesReadOnly(PrintoutOnly)
Exit()
End()

[SubProc]

[IsCPToolsShell]
IniName = system.ini
SectionName = boot
shell = *wndt.exe

[ActMailInBox]
reset = TARGET4
Location=%s\remote\in, TARGET

[ActMailFiles]
armail.dbf, TARGET2

[IsAutoexecBat]
c:\autoexec.bat

[AutoexecBat]
autoexec.bat, TARGET4

[DriveRoot]
reset = TARGET4
location = c:\

[KillAAUItem]
dll = custom.dll
function = KillAAUItem

[Actwin2Ini]
actwin2.ini, WINDOWS

[RemoveOldExt]
IniName = actwin2.ini
SectionName = "Me Record"
"Me Fax Ext"=*

[MailIni]
actmail.ini, WINDOWS

[NetFiles]
install.inf, TARGET

[WhereIsACT]
caption = "Locate your copy of ACT! 2.0"
reset = TARGET
DefaultDir = f:\actwin2

[WinDlls]
arcb51.dll, arcb51.ins, SYSTEM, TARGET
arfunc.dll, arfunc.ins, SYSTEM, TARGET
armail.dll, armail.ins, SYSTEM, TARGET
custom.dll, custom.ins, WINDOWS, TARGET

[PrintoutFiles]
fullpage.adr, TARGET5 
fullpage.day, TARGET5
fullpage.mon, TARGET5
fullpage.wee, TARGET5
halfpage.adr, TARGET5
halfpage.day, TARGET5
halfpage.wee, TARGET5
lrgpckt.adr, TARGET5 
lrgpckt.day, TARGET5 
smlpckt.adr, TARGET5 
smlpckt.day, TARGET5 

[newprint]
prengine.dll, TARGET

[IsNetTarget]
dll = custom.dll
function = IsNetDrive

[Docs]
%s\docs, TARGET

[DataBaseSync]
%s\database\synch, TARGET

[IsActresValid]
dll = custom.dll
function = IsACTResValid

[aauexe]
aau.exe, TARGET

[aauhlp]
aau.hlp, TARGET

[DoPassword]
dll = custom.dll
function = DoPassword

[ActNotInstalled]
caption="ACT! Mobile Link 2.0 Upgrade"
"The installer did not find a previously installed"
"version of ACT! 2.0 on your machine."
""
"This product is an upgrade only. Contact"
"your local dealer about purchasing ACT! 2.0."

[groups]
"ACT! 2.0 for Windows",       actwin2.grp

[ACT! 2.0 for Windows]
"ACT!",     actwin2.exe,     appfiles
"Read Me",  readme.txt,      appfiles

[TargetDrive]
caption = "ACT! Mobile Link 2.0 Installation"
defpath = C:\actwin2
text    = "Enter the drive and directory containing ACT! 2.0."
reqspace= "Approximate disk space required"

[BcaseDIR]
%s\bcase, TARGET

[OutboxDIR]
%s\Outbox, TARGET

[QueryDIR]
%s\queries, TARGET

[DeferredDIR]
%s\Deferred, TARGET

[DoCSDLL]
dll = custom.dll
function = DoCustomScreen

[DoRegDLL]
dll = custom.dll
function = DoOnlineRegistration

[FileCopy]
errorcaption = "ACT! Mobile Link 2.0 Installation Error"
insertcaption = "ACT! Mobile Link 2.0 Installation"

[cancel]
caption = "ACT! Mobile Link 2.0 Installation"
text = "Are you sure you want to exit?"

[Errors]
nohelp = "Help is not currently working"

[custdll]
custom.dll, custom.dll, SOURCE, WINDOWS
actlpfnc.dll, actlpfnc.dll, SOURCE, WINDOWS

[WindowsVersion]
3.10
"ACT! Mobile Link 2.0 requires"
"Windows 3.1 or greater."

[THANKS]
caption="ACT! Mobile Link 2.0"
"Your installation was successful."
""
"Thank you for choosing ACT! Mobile Link 2.0"

[pix]
color = %s\actback.bmp, 1, 1
color = %s\symlogo.rle, 1, -1

[pix2]
color = %s\actback.bmp
color = %s\symlogo.rle, 1, -1

[Arccopy:CopyDialog]
caption = "Copying ACT! Mobile Link 2.0 Files..."
posx = -10
posy = -10

[Arccopy:Advo]
posx = 10
posy = 60
count = 4
location = custom.dll
BitmapsOnly = 1

[AdvoDefault]
posx = 20
posy = 30
text = AdvoText

[AdvoText]
"Please take a moment to complete the Product Registration Card
"included with your product and return it to Symantec."
""
"This will ensure that you receive future product announcements"
"and important notices. It will also qualify you for any discounts"
"on future upgrades."
""
"Thank you for purchasing ACT! Mobile Link 2.0"

[IsActRunning]
dll = custom.dll
function = IsACTRunning

[ActIsRunning]
caption="WARNING"
"The installer has detected a version of"
"ACT! currently running on your machine."
""
"Exit ACT! and run the installer again"

[CSDLL]
Custom.dll, WINDOWS
actlpfnc.dll, WINDOWS
cramapi.dll, TARGET	
pipeline.dll, TARGET
pipeline.ini, TARGET
pipereg.ini, TARGET
pipereg.ini, WINDOWS
regdll.dll, TARGET	
slidshow.fss, TARGET
sslib.dll, TARGET	
modem.id, TARGET

[AddExts]
IniName = win.ini
SectionName = extensions
dbf="%s\actwin2.exe ^.dbf", TARGET
wpd="%s\actwin2.exe ^.wpd", TARGET
SectionName=WfxPbLinks
ACT!PhoneBook="1,%s\ACTWIN2.EXE,ACTWIN2,ACTWINPB,ActFrameClass", TARGET

[CreateConfigFile]
dll = custom.dll
function = CreateLicenseDir
DirName = license
ConfigFile = lpactwin.bin

[FirstLanpack]
dll  = actlpfnc.dll
function = InstallLanpack
Caption = "ACT! Mobile Link 2.0 Network Installation"
Text    = "Locate the ACT! Mobile Link 2.0 network directory."
ConfigFile = lpactwin.bin
License = "lpactwin.lms"
Description = "lpactwin.dat"
Appname = "actwin2.exe"
First = TRUE

[SaveEm]
win.ini, winini.act, WINDOWS, WINDOWS

[pipeline]
cramapi.dll,    cramapi.dll,    SOURCE,     TARGET	
pipeline.dll,   pipeline.dll,   SOURCE,     TARGET
pipeline.ini,   pipeline.ini,   SOURCE,     TARGET
regdll.dll,     regdll.dll,     SOURCE,     TARGET	
slidshow.fss,   slidshow.fss,   SOURCE,     TARGET
sslib.dll,      sslib.dll,      SOURCE,     TARGET	
 
[Wayin]
Custom.dll, WINDOWS
actlpfnc.dll, WINDOWS

[application]
Caption = "Searching..."
Text 1= "Searching for ACT! 2.0"
Appname = "actwin2.exe"
Apppath = c:\actwin2

[IniFiles]
reset = TARGET2
location = %s\remote, TARGET

[RemoteDIR]
%s\remote, TARGET

[RemoteInDIR]
%s\remote\in, TARGET

[RemoteOutDIR]
%s\remote\out, TARGET

[RemoteElrDIR]
%s\remote\elr, TARGET

[MailDIR]
%s\mail, TARGET

[DocsDIR]
%s\docs, TARGET

[ACTMAIL1]
IniName = ACTMAIL.INI
SectionName = General
ClientOpenSystem = 1
ClientAutoEnabled = 1
PersonalAddressList = 1

[ACTMAIL2]
IniName = ACTMAIL.INI
SectionName = Paths
Transport = %s\artrnspt.exe, TARGET2
LiteratureRack = %s\elr, TARGET2
MsgOutbox = %s\out, TARGET2
MsgInbox = %s\in, TARGET2
AddressDB = %s\armail.dbf, TARGET2

[ACTMAIL3]
IniName = ACTMAIL.INI
SectionName = "Client Transport"
DestMail = arsvmail.dll
DestDB = arsvmail.dll
Driver = %s\arasync.dll, TARGET2
SourceMail = %s\armail.dll, SYSTEM

[ACTMAIL4]
IniName = ACTMAIL.INI
SectionName = "Client Transaction Types"
1100 = "ARELRSRV.dll, elrProcess", TARGET2

[ACTWIN1]
IniName = ACTWIN2.INI
SectionName = Paths
Remote = %s, TARGET2

[WinIniAust]
IniName = WIN.INI
SectionName = Actwin2
CountryVersion = 1

[WinIniCan]
IniName = WIN.INI
SectionName = Actwin2
CountryVersion = 2

[WinIniEuro]
IniName = WIN.INI
SectionName = Actwin2
CountryVersion = 3

[WinIniLatin]
IniName = WIN.INI
SectionName = Actwin2
CountryVersion = 4

[WinIniUk]
IniName = WIN.INI
SectionName = Actwin2
CountryVersion = 5

[WinIniUs]
IniName = WIN.INI
SectionName = Actwin2
CountryVersion = 6

[Filters]
Reset=TARGET2
Location=%s\Filters, TARGET

[Layouts]
Reset=TARGET3
Location=%s\Layouts, TARGET

[Mail]
Reset=TARGET4
Location=%s\Mail, TARGET

[Printout]
Reset=TARGET5
Location=%s\Printout, TARGET

[ExeOnly]
*.EXE, TARGET

[DLLONLY]
*.DLL, TARGET

[FiltersOnly]
*.FLT, TARGET2

[LayoutsOnly]
*.lay, TARGET3

[MailOnly]
*.msg, TARGET4

[PrintoutOnly]
*.*, TARGET5	

[Arccopy]
copymain.appfiles,              "Application and System Files",                        0,N,Y,Y
