coucou Posted April 23, 2010 Share Posted April 23, 2010 (edited) Hi,Since yesterday I try installing with the here bellow script, the Vista Codecs Package prog. It well installed but at the end i get AutoIt Error message (see bellow) AutoIt Error Line 36 (File "C:\Test\Vista Codec\VistaCodecs_Install.exe"): Error: Illegal text at the end of statement (one statement per line)In fact, I don't silent install the prog by a swiychless (prog.msi/qb) to prevent the Bing Toolbar (ad) installation.Here my scriptexpandcollapse popupAdlibRegister("_Adlib") Opt('TrayIconDebug', 1) $title = "Vista Codec Package - VistaCodecs Installer" ;Run("msistub.exe VistaCodecs_v568.msi") ShellExecute("VistaCodecs_v568.msi") ;Welcome WinWaitActive($title, "Welcome") Sleep(2000) ControlClick($title, "Welcome", "Button1") ;License Agreement WinWaitActive($title, "License Agreement") Sleep(500) ControlClick($title, "License Agreement", "Button3"); I accept Sleep(500) ControlClick($title, "License Agreement", "Button5"); Next ;Destination Folder WinWaitActive($title, "Destination Folder") Sleep(500) ControlClick($title, "Destination Folder", "Button1"); Next ;Installing the Bing Toolbar WinWaitActive($title, "Installing the Bing Toolbar") Sleep(500) ControlClick($title, "Installing the Bing Toolbar", "Button4"); Uncheck Sleep(500) ControlClick($title, "Installing the Bing Toolbar", "Button1"); Next ;Setup Type WinWaitActive($title, "Setup Type") Sleep(500) ControlClick($title, "Setup Type", "Button5"); Complete and Next ;Install WinWaitActive($title, "Ready to Install") Sleep(500) ControlClick($title, "Ready to Install", "Button1") ;Finish WinWaitActive($title, "The InstallShield") Sleep(2000) ControlClick($title, "The InstallShield", "Button1") Sleep(3000) ;Process Close ProcessWait("iexplore.exe", 50) Sleep(500) For $i = 1 To 10 Step 1 If ProcessExists("iexplore.exe") Then ProcessClose("iexplore.exe") Sleep(500)) Else ExitLoop EndIf Next Func _Adlib() If WinExists("AutoIt Error", "") Or @error Then ControlClick("AutoIt Error", "", "Button1") ;OK AdlibUnRegister("_Adlib") EndIf EndFuncI'll appreciate any help to get ride from that errorRegards Edited April 23, 2010 by coucou Link to comment Share on other sites More sharing options...
trancexx Posted April 23, 2010 Share Posted April 23, 2010 You have one closing parenthesis too many with Sleep. ♡♡♡ . eMyvnE Link to comment Share on other sites More sharing options...
coucou Posted April 23, 2010 Author Share Posted April 23, 2010 You have one closing parenthesis too many with Sleep.You are right. Especially with this prog.I noticed when NO Sleep, the script go much fast than the windows prog (the ControlClick miss its WinWaitActive).Regards Link to comment Share on other sites More sharing options...
coucou Posted April 25, 2010 Author Share Posted April 25, 2010 No one can help???What a pitty Link to comment Share on other sites More sharing options...
Moderators Melba23 Posted April 25, 2010 Moderators Share Posted April 25, 2010 coucou,trancexx has given you the answer. In line 55 of your script you have:Sleep(500))where you should have:Sleep(500)Before you ask, the reason the error is listed as line 36 in the dialog is because all comments and blank lines are stripped when you compile. Count through the script and you will find that the line in question is the 36th statement line. M23 Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind Open spoiler to see my UDFs: Spoiler ArrayMultiColSort ---- Sort arrays on multiple columnsChooseFileFolder ---- Single and multiple selections from specified path treeview listingDate_Time_Convert -- Easily convert date/time formats, including the language usedExtMsgBox --------- A highly customisable replacement for MsgBoxGUIExtender -------- Extend and retract multiple sections within a GUIGUIFrame ---------- Subdivide GUIs into many adjustable framesGUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView itemsGUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeViewMarquee ----------- Scrolling tickertape GUIsNoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxesNotify ------------- Small notifications on the edge of the displayScrollbars ----------Automatically sized scrollbars with a single commandStringSize ---------- Automatically size controls to fit textToast -------------- Small GUIs which pop out of the notification area Link to comment Share on other sites More sharing options...
coucou Posted April 25, 2010 Author Share Posted April 25, 2010 TNX Melba23, yet I searched... but i couldn't see it. TNX again trancexx Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now