pendal Posted April 17, 2009 Posted April 17, 2009 I need to run this command 7za.exe a files.7z c:\files but the dir c:\files is about 2 gigs in size so it takes about 10 minutes to compress. how do I tell autoit to wait until the command is complete before continuing. the 7za.exe command outputs the words "Everything is OK" to the cmd window when it is finished. Is there anyway to search for that string in the window?
Developers Jos Posted April 17, 2009 Developers Posted April 17, 2009 RunWait() ? Jos SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past.
pendal Posted April 17, 2009 Author Posted April 17, 2009 RunWait() ? Jos Here is what i have so far. if DirGetSize($sPath &"\"& $array[$n] &"\"& $nFolder &"\Plates") > 1073741824 Then ;if the directory is larger than 999MB ... size must be in bytes. Run("cmd.exe") WinWaitActive("C:\WINDOWS\system32\cmd.exe") send($compLocation & " a " & $sPath &"\"& $array[$n] &"\"& $nFolder &"\Plates.7z " & $sPath &"\"& $array[$n] &"\"& $nFolder &"\Plates\*{ENTER}", 0)) ;check to see if the archive is done compressing. ;need to know what goes here. ;close the cmd window. send("Exit{ENTER}",0) EndIF If i am approaching this the wrong way .. please let me know. Thanks in advance. P
Developers Jos Posted April 17, 2009 Developers Posted April 17, 2009 I would use either RunWait() or ShellExecuteWait(). Just have a look at those in the Helpfile. Jos SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past.
pendal Posted April 17, 2009 Author Posted April 17, 2009 I would use either RunWait() or ShellExecuteWait(). Just have a look at those in the Helpfile.JosThanks a million .. this software is the MAC-DADDY!!
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