Here is what I have so far:
Code: Select all
SetTitleMatchMode, 2
SetTitleMatchMode, Slow
Run, "C:\path\to\my\program.exe",, Max, PID ;
;wait 5 seconds, the dialog is slow
SetControlDelay, 5000
;click the Connect button on the dialog that has "MY VPN Client" in the title
ControlClick, Connect, MY VPN Client
;wait 5 seconds, the dialog is slow
SetControlDelay, 5000
;send username and password to the dialog that has "Login" in the title
ControlSend, Edit, myusername{tab}, Login
ControlSend, Edit, mysecretpassword, Login
;click the OK button on the dialog that has "Login" in the title
ControlClick, OK, Login
Jim