Jump to content
Sign in to follow this  
jameelo25

Counting Up in AutoIt

Recommended Posts

jameelo25
Posted (edited)

Hey everyone , I want to make a "While" or loop in Autoit where the program counts up numbers automatically in my notepad, starting from the number 5000.

So I want it to write this every 2 seconds automatically :

5001

2 secs

5002

2 secs 

5003

 

I don't really know how to do this without writing " send("5003") ", then "send("5004") " then "send(5005)"  every single time, any help would be greatly appreciated :D

Edited by jameelo25

Share this post


Link to post
Share on other sites
JLogan3o13
Posted (edited)

@jameelo25 in short, something like this:

for $x = 5000 to 6000
    Send($x)
    Sleep(2000)
Next

Just realize that Send is unreliable - it doesn't care what window is active. If you have a specific window/program in mind, look at ControlSend in the help file.

Edited by JLogan3o13
  • Like 1

√-1 2^3 ∑ π, and it was delicious!

How to get your question answered on this forum!

Share this post


Link to post
Share on other sites
jameelo25

thanks, i'll try that @JLogan3o13:)

Share this post


Link to post
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×