Sign in to follow this  
Followers 0
Ham123

Looping a key over and over

6 posts in this topic

I understand how to loop a key

However, lets say I have to do this a hundred times, with different keys. Rather than copy pasting this sequence over and over again, is there an easier way?

Thank you.

Share this post


Link to post
Share on other sites



I understand how to loop a key

However, lets say I have to do this a hundred times, with different keys. Rather than copy pasting this sequence over and over again, is there an easier way?

Thank you.

$i = 1

While $i <= 100

$i = $i + 1

Send ("a")

WEnd

You could try that, I think what it does is keep adding 1 onto $i, so when it reaches 100 it will stop. In the Send ("a") bit you just put what key you want to use.

Share this post


Link to post
Share on other sites

$i = 1

While $i <= 100

$i = $i + 1

Send ("a")

WEnd

You could try that, I think what it does is keep adding 1 onto $i, so when it reaches 100 it will stop. In the Send ("a") bit you just put what key you want to use.

Yup, thats what i did before, i was thinking of how to do this somewhat differently though.

For example:

Send( "{FORWARD ARROW KEY}" ) for 4.02 seconds

is there any way to do this?

Share this post


Link to post
Share on other sites

what ever happened to good old fashioned For loops?

For $i = 0 to 99

next

Share this post


Link to post
Share on other sites

what ever happened to good old fashioned For loops?

For $i = 0 to 99

next

that does lighten the load hah didnt know about the command "next"

thank you :)

Share this post


Link to post
Share on other sites

For example:

Send( "{FORWARD ARROW KEY}" ) for 4.02 seconds

is there any way to do this?

SendKeyDownDelay

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  
Followers 0