Ahmedwia Posted July 26, 2014 Share Posted July 26, 2014 I created a script to help me copy some text from a notpad and past it into a software, I want it to run 10 times in a loop but I don't know how to do that because I'm not a programmer. This is the script: MouseClick("left", 1840, 139, 2, 500) Sleep(200) Send("^x") Sleep(200) Send("{DEL}") Sleep(100) MouseClick("left", 600, 840, 2, 500) Sleep(300) Send("^v") Sleep(300) Send("{ENTER}") Could someone help me please? Link to comment Share on other sites More sharing options...
l3ill Posted July 26, 2014 Share Posted July 26, 2014 Hi, and welcome to the forums !! Have a look in the help file under: Language Reference - Loop Statements - For ..Next Give it a shot and come back if you get stuck. Good Luck ! Bill My Contributions... SnippetBrowser NewSciTE PathFinder Text File Manipulation FTP Connection Tester / INI File - Read, Write, Save & Load Example Link to comment Share on other sites More sharing options...
Solution Geir1983 Posted July 26, 2014 Solution Share Posted July 26, 2014 $Repeat = 10 For $idx=1 to $Repeat MouseClick("left", 1840, 139, 2, 500) Sleep(200) Send("^x") Sleep(200) Send("{DEL}") Sleep(100) MouseClick("left", 600, 840, 2, 500) Sleep(300) Send("^v") Sleep(300) Send("{ENTER}") Next Link to comment Share on other sites More sharing options...
Ahmedwia Posted July 26, 2014 Author Share Posted July 26, 2014 Thank you l3ill & Geir1983 for your help, my script worked the way I wanted after I used Geir1983 example Link to comment Share on other sites More sharing options...
somdcomputerguy Posted July 26, 2014 Share Posted July 26, 2014 I think you would've gotten your script to work the way you want if if you had followed l3ill's example.. - Bruce /*somdcomputerguy */ If you change the way you look at things, the things you look at change. 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