Sign in to follow this  
Followers 0
Marty4

Need mouseclick function to operate after keystrokes

2 posts in this topic

When my script runs, the MouseMove function is occuring before my Send functions. Basically I need a set of Send functions occur first before the mousemove function occurs. How is this possible? The structure I need is this: send, send, send, send, mousemove, mouse click, mouse move, mouse click. Actually, there are about 20 Send functions that I need to occure before the mousemoves and mouseclicks. Any help would be apprecaited.

Marty

Share this post


Link to post
Share on other sites



When my script runs, the MouseMove function is occuring before my Send functions. Basically I need a set of Send functions occur first before the mousemove function occurs. How is this possible? The structure I need is this: send, send, send, send, mousemove, mouse click, mouse move, mouse click. Actually, there are about 20 Send functions that I need to occure before the mousemoves and mouseclicks. Any help would be apprecaited.

Marty

It's probably the application taking a while to process the keys sent. So try inserting a Sleep() after the sends and before the mouse commands

e.g.

Send("A")
Send("A")
Send("A")
Send("A")
Send("A")
Sleep(500) ;wait for half a second
MouseMove()
MouseMove()
MouseClick()

"Programming today is a race between software engineers striving to build bigger and better idiot-proof programs, and the universe trying to build bigger and better idiots. So far, the universe is winning."- Rick Cook

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