Вот
читать дальше »
;
предотвращение возможности множественного запуска скрипта
If WinExists(@ScriptName) Then Exit
AutoItWinSetTitle(@ScriptName)
AutoItSetOption("TrayIconDebug", 1)
AutoItSetOption("SendKeyDelay", 10)
If ProcessExists ( "punto.exe" )<>0 Then
ProcessClose ( "punto.exe" )
ProcessWaitClose ( "punto.exe" )
EndIf
$Title='Alcohol'
$SetupFile='Alcoholsetup.exe'
$InstallPath=@ProgramFilesDir & '\Alcohol'
run($SetupFile)
winwaitactive($Title,'Welcome to the Alcohol')
send('{ENTER}')
winwaitactive($Title,'License Agreement')
send('{ENTER}')
if winexists($Title,'Already Installed') Then
winwaitactive($Title,'Already Installed')
send('{ENTER}')
endif
if winexists($Title,'Not for Business Use') Then
winwaitactive($Title,'Not for Business Use')
send('{space}')
sleep(100)
send('{ENTER}')
endif
winwaitactive($Title,'Choose Components')
send('{ENTER}')
winwaitactive($Title,'Choose Install Location')
send($InstallPath)
send('{ENTER}')
sleep(1000)
winwaitactive($Title,'Completing the Alcohol')
send('{space}')
sleep(100)
send('{ENTER}')