4Bravo Posted November 6, 2012 Share Posted November 6, 2012 (edited) I'm continuing to have problems with Flash and Autoit. This time I am able to execute everything I want on the first item in an array, but as soon as the second item in the array loads the script stops. I used to be able to try to jump start the script by getting it to the next WinWaitActive window, but that does not seem to work anymore I changed my hotkeys to use plain menu keys to navigate around as I thought that might have been the problem, but it does not help nor hinder the problem expandcollapse popup#include <Array.au3> #include <RecFileListToArray.au3> $sPath = "D:AnimationsCYOAApplicationApplication_AssetsCharacter_RendersHero_Anim" $FileList = _RecFileListToArray($sPath, "*.fla", 1, 1, 1, 2) $justFILE = _RecFileListToArray($sPath, "*.fla", 1, 1, 1, 0) $flaDIR = _RecFileListToArray($sPath, "*.fla", 1, 1, 1, 2) For $i = 1 To $justFILE[0] $justFILE[$i] = StringTrimRight($justFILE[$i], 4) next For $i = 1 To $flaDIR[0] $flaDIR[$i] = StringReplace($flaDIR[$i], $justFILE[$i] & ".fla", "") next For $i = 1 To $FileList[0] Run("C:Program Files (x86)AdobeAdobe Flash CS5.5flash.exe " & $FileList[$i]) WinWaitActive($justFILE[$i]) WinWaitNotActive("Adobe Flash CS5.5") ;export movie Send("!") Send("f") Send("e") Send("m") WinWaitActive("Export Movie") ; set new filepath and name ;Use this line if you want the render to have the same name as the movie ;Send($flaDIR[$i] & $justFILE[$i] & ".Mov") Send($flaDIR[$i] & "Render.Mov") Send("{ENTER}") ;overwrite if file exists WinWaitActive("Confirm Save As", "", 1) Send("{y}") WinWaitActive("QuickTime Export Settings") ; dismiss export settings dialg Send("{ENTER}") WinWaitActive("Adobe Flash CS5.5") ; dismiss export settings dialg Send("{ENTER}") ; wait for export to finish WinWaitActive($justFILE[$i]) ; close .fla file Sleep(1000) Send("!") Send("f") Send("c") WinWaitActive("Adobe Flash CS5.5") Next I added the WinWaitNotActive("Adobe Flash CS5.5") after the file loads just to double check that the file was open, it hasn't changed the problem. Any thoughts? Edited November 6, 2012 by 4Bravo Link to comment Share on other sites More sharing options...
DicatoroftheUSA Posted November 6, 2012 Share Posted November 6, 2012 Try adding AutoItSetOption("TrayIconDebug",True) near the top of your script so you can see exactly where it is hangning by mouseing over the tray icon. Statism is violence, Taxation is theft. Autoit Wiki Link to comment Share on other sites More sharing options...
4Bravo Posted November 7, 2012 Author Share Posted November 7, 2012 Thanks! The problem was the sorted parameter in the _RecFileListToArray was actually sorting the files differently 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