Jump to content

Need help running 2 scripts to 2 different windows


Recommended Posts

Hi, I just started using autoit and im looking for a way to do a pixelgetcolor and click in a window, then do the same in a different window. For the 1st scripted, I'm using something along the lines of

WinActivate("prog1")
WinWaitActive("prog1")
MouseClick("left", 470, 345 )   
ControlSend("prog1", "", "", "bla bla bla")

in the 2nd script i have "prog2" instead........it doesnt switch windows like i thought it would.

Any ideas?

Link to post
Share on other sites

WinActivate("prog1")
WinWaitActive("prog1")
MouseClick("left", 470, 345 )    
Send("bla bla bla")

WinActivate("prog2")
WinWaitActive("prog2")
MouseClick("left", 470, 345 )    
Send("bla bla bla")
That should work, provided that "prog1" and "prog2" are the Window titles. See the help file under WinTitleMatchMode.

[size="1"][font="Arial"].[u].[/u][/font][/size]

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
  • Recently Browsing   0 members

    No registered users viewing this page.

×
×
  • Create New...