Hexavolt Posted October 7, 2010 Share Posted October 7, 2010 I am trying to make a simple key -> click -> wait -> key -> wait looping command. But with about 3 hours of trying to figure out where I am going wrong, I still can't make sense of it. I keep getting unterminated string error. If you could direct me to the mistake I would greatly appreciate it. Thank you for your time and consideration. #region ---Au3Recorder generated code Start --- Opt("WinWaitDelay",100) Opt("WinDetectHiddenText",1) Opt("MouseCoordMode",0) _WinWaitActivate("untiltled)","") myloop: MouseClick("left",401,321,1) Send("{F5}") MouseClick("left",401,321,1) Sleep, (3000) Send("{INS}") Sleep, (3000) Goto, myloop") #region --- Internal functions Au3Recorder Start --- Func _WinWaitActivate($title,$text,$timeout=0) WinWait($title,$text,$timeout) If Not WinActive($title,$text) Then WinActivate($title,$text) WinWaitActive($title,$text,$timeout) EndFunc #endregion --- Internal functions Au3Recorder End --- #endregion --- Au3Recorder generated code End --- Link to comment Share on other sites More sharing options...
ShawnW Posted October 7, 2010 Share Posted October 7, 2010 (edited) that is not how you loop in autoit. Try a While loop or something Replace myloop: with While True or While 1 if you prefer then replace Goto, myloop") with WEnd Edit: Also no , after Sleep just Sleep(3000) Edited October 7, 2010 by ShawnW Link to comment Share on other sites More sharing options...
Hexavolt Posted October 7, 2010 Author Share Posted October 7, 2010 (edited) that is not how you loop in autoit.Try a While loop or somethingReplace myloop:with While Trueor While 1 if you preferthenreplace Goto, myloop") with WEnd Thank you... I had gotten the loop command from a "Autoit_quickref.pdf" (it may be out of date I suppose) and I did what you recommended but I am still getting the unterminated string error on the final line (14)EDIT: same after fixing the sleep command.ReEDIT: :FACEPALM: i fixed it thank you (shouldn't have been editing in AU3Record...) Edited October 7, 2010 by Hexavolt 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