Shaitan Posted January 27, 2015 Share Posted January 27, 2015 (edited) Hello again. I'm building a Windows 8.1 unattended setup using AutoIt to install most of the softwares. I already built several unattended setups since Windows XP but now I'm facing a few weird and boring issues. For instance, when I try to install Adobe Reader XI, AutoIt doesn't launch Reader's installer and if I do it with a batch file, AutoIt seems to ignore any command I try, it even move the mouse pointer. Actually, the only thing it does is to active the Reader's installer window. The same problem happens with Skype for Desktop, WinRAR and several others. start AdobeReader/AdbeRdr11000_pt_BR.exe exit Opt("WinWaitDelay",100) Opt("WinTitleMatchMode",4) Opt("WinDetectHiddenText",1) Opt("MouseCoordMode",1) Run("AdobeReader.cmd") WinWait("Adobe Reader XI", "") If Not WinActive("Adobe Reader XI", "") Then WinActivate("Adobe Reader XI", "") WinWaitActive("Adobe Reader XI", "") MouseClick("left", 301, 225) Edited January 27, 2015 by Shaitan Link to comment Share on other sites More sharing options...
BrewManNH Posted January 27, 2015 Share Posted January 27, 2015 Why not build a computer, put the software you want on it, and then image that computer to clone it to the rest? Installing Windows and then all the support software over and over again is a waste of time if they're all going to have the same software on them in the end. If I posted any code, assume that code was written using the latest release version unless stated otherwise. Also, if it doesn't work on XP I can't help with that because I don't have access to XP, and I'm not going to.Give a programmer the correct code and he can do his work for a day. Teach a programmer to debug and he can do his work for a lifetime - by Chirag GudeHow to ask questions the smart way! I hereby grant any person the right to use any code I post, that I am the original author of, on the autoitscript.com forums, unless I've specifically stated otherwise in the code or the thread post. If you do use my code all I ask, as a courtesy, is to make note of where you got it from. Back up and restore Windows user files _Array.au3 - Modified array functions that include support for 2D arrays. - ColorChooser - An add-on for SciTE that pops up a color dialog so you can select and paste a color code into a script. - Customizable Splashscreen GUI w/Progress Bar - Create a custom "splash screen" GUI with a progress bar and custom label. - _FileGetProperty - Retrieve the properties of a file - SciTE Toolbar - A toolbar demo for use with the SciTE editor - GUIRegisterMsg demo - Demo script to show how to use the Windows messages to interact with controls and your GUI. - Latin Square password generator Link to comment Share on other sites More sharing options...
Shaitan Posted January 27, 2015 Author Share Posted January 27, 2015 Why not build a computer, put the software you want on it, and then image that computer to clone it to the rest? Installing Windows and then all the support software over and over again is a waste of time if they're all going to have the same software on them in the end. It's not meant to be installed in several computers. I'm building basically for me and I like to customize Windows as much as I can but hate to reinstall a lot of softwares every month. Link to comment Share on other sites More sharing options...
jchd Posted January 27, 2015 Share Posted January 27, 2015 Isn't "every month" the actual and only problematic part of the whole question?Anyw Anyway, that it be for hundreds machine or yours only but routinely, an image would certainly be the best choice. This wonderful site allows debugging and testing regular expressions (many flavors available). An absolute must have in your bookmarks.Another excellent RegExp tutorial. Don't forget downloading your copy of up-to-date pcretest.exe and pcregrep.exe hereRegExp tutorial: enough to get startedPCRE v8.33 regexp documentation latest available release and currently implemented in AutoIt beta. SQLitespeed is another feature-rich premier SQLite manager (includes import/export). Well worth a try.SQLite Expert (freeware Personal Edition or payware Pro version) is a very useful SQLite database manager.An excellent eBook covering almost every aspect of SQLite3: a must-read for anyone doing serious work.SQL tutorial (covers "generic" SQL, but most of it applies to SQLite as well)A work-in-progress SQLite3 tutorial. Don't miss other LxyzTHW pages!SQLite official website with full documentation (may be newer than the SQLite library that comes standard with AutoIt) Link to comment Share on other sites More sharing options...
Shaitan Posted January 27, 2015 Author Share Posted January 27, 2015 The problematic part of the whole question is the fact that for some reason Im not being able to make AutoIt works like it used to work before. Link to comment Share on other sites More sharing options...
pcjunki Posted January 28, 2015 Share Posted January 28, 2015 try shellexecute call the reader installer with the switch /sAll Link to comment Share on other sites More sharing options...
nitekram Posted January 28, 2015 Share Posted January 28, 2015 Also, and I may be wrong, but I would think you would want to run the EXE that is the installer? Opt("WinWaitDelay",100) Opt("WinTitleMatchMode",4) Opt("WinDetectHiddenText",1) Opt("MouseCoordMode",1) Run("AdbeRdr11000_pt_BR.exe") ; may need the path to the location as well, or just put in the same folder as the script WinWait("Adobe Reader XI", "") If Not WinActive("Adobe Reader XI", "") Then WinActivate("Adobe Reader XI", "") WinWaitActive("Adobe Reader XI", "") MouseClick("left", 301, 225) 2¢ All by me:"Sometimes you have to go back to where you started, to get to where you want to go." "Everybody catches up with everyone, eventually" "As you teach others, you are really teaching yourself." From my dad "Do not worry about yesterday, as the only thing that you can control is tomorrow." WIKI | Tabs; | Arrays; | Strings | Wiki Arrays | How to ask a Question | Forum Search | FAQ | Tutorials | Original FAQ | ONLINE HELP | UDF's Wiki | AutoIt PDF AutoIt Snippets | Multple Guis | Interrupting a running function | Another Send StringRegExp | StringRegExp Help | RegEXTester | REG TUTOR | Reg TUTOT 2 AutoItSetOption | Macros | AutoIt Snippets | Wrapper | Autoit Docs SCITE | SciteJump | BB | MyTopics | Programming | UDFs | AutoIt 123 | UDFs Form | UDF Learning to script | Tutorials | Documentation | IE.AU3 | Games? | FreeSoftware | Path_Online | Core Language Programming Tips Excel Changes ControlHover.UDF GDI_Plus Draw_On_Screen GDI Basics GDI_More_Basics GDI Rotate GDI Graph GDI CheckExistingItems GDI Trajectory Replace $ghGDIPDll with $__g_hGDIPDll DLL 101? Array via Object GDI Swimlane GDI Plus French 101 Site GDI Examples UEZ GDI Basic Clock GDI Detection Ternary operator Link to comment Share on other sites More sharing options...
pcjunki Posted January 28, 2015 Share Posted January 28, 2015 the adobe reader full installer has command line options for installing download the full installer here http://www.adobe.com/support/downloads/thankyou.jsp?ftpID=5507&fileID=5519 unzip ShellExecute ("C:\somefolder\bla\bla\bla\AdbeRdr11000_mui_Std\setup.exe" , "/sAll") Link to comment Share on other sites More sharing options...
JohnOne Posted January 28, 2015 Share Posted January 28, 2015 The problematic part of the whole question is the fact that for some reason Im not being able to make AutoIt works like it used to work before. I don't believe there have been any script braking changes in any of the functions you use. But there may have been in other in your code, worth a check. AutoIt Absolute Beginners Require a serial Pause Script Video Tutorials by Morthawt ipify Monkey's are, like, natures humans. Link to comment Share on other sites More sharing options...
pcjunki Posted January 28, 2015 Share Posted January 28, 2015 this will download the full version of reader extract and silently install #include <inet.au3> InetGet("http://ardownload.adobe.com/pub/adobe/reader/win/11.x/11.0.00/misc/AdbeRdr11000_mui_Std.zip", @DesktopDir & "/AdbeRdr11000_mui_Std.zip") $vbs = (@DesktopDir & "/extract.vbs") FileOpen($vbs, 0) FileWrite($vbs, 'ZipFile="AdbeRdr11000_mui_Std.zip"' & @CRLF) FileWrite($vbs, 'ExtractTo="AdbeRdr11000_mui_Std"' & @CRLF) FileWrite($vbs, 'Set fso = CreateObject("Scripting.FileSystemObject")' & @CRLF) FileWrite($vbs, 'If NOT fso.FolderExists(ExtractTo) Then' & @CRLF) FileWrite($vbs, ' fso.CreateFolder(ExtractTo)' & @CRLF) FileWrite($vbs, 'End If' & @CRLF) FileWrite($vbs, 'set objShell = CreateObject("Shell.Application")' & @CRLF) FileWrite($vbs, 'set FilesInZip=objShell.NameSpace(ZipFile).items' & @CRLF) FileWrite($vbs, 'objShell.NameSpace(ExtractTo).CopyHere(FilesInZip)' & @CRLF) FileWrite($vbs, 'Set fso = Nothing' & @CRLF) FileWrite($vbs, 'Set objShell = Nothing' & @CRLF) FileClose($vbs) Sleep(2000) RunWait(@ComSpec & ' /c ' & 'cscript %userprofile%\desktop\extract.vbs', "", @SW_HIDE) FileDelete($vbs) ShellExecute(@DesktopDir & "/AdbeRdr11000_mui_Std/setup.exe", "/Sall") Link to comment Share on other sites More sharing options...
Shaitan Posted January 28, 2015 Author Share Posted January 28, 2015 Looks like I found the problem. AutoIt needs to execute the scripts with administrator rights, so it worked perfectly after I added #RequireAdmin and #pragma compile(ExecLevel, requireAdministrator) 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