Jump to content
Sign in to follow this  
Sravanth

Clicking on a control which changes its control id

Recommended Posts

Sravanth

In deep freeze the controlid's are changing for all the controls present in it. So how shall i click on a particular control without using control id's.

mouseclick fn cant help if the resolution is changed, so cant even use it. so how can i use controlclick in the above mentioned case.

Share this post


Link to post
Share on other sites
monoscout999

Check the class and the instance.

Share this post


Link to post
Share on other sites
boogieoompa

Another thing you can do is use relative positions. Basically before you do a mouse click find out how big the window is and where it is at. Than click based on a percentage of that value (or hard coded if you know specific values for the width or height).

Cheers

$windowdimension = WinGetPos()
$winxposition = $windowdimension[0]
$winyposition = $windowdimension[1]
$winwidth = $windowdimension[2]
$winheight = $windowdimension[3]

MouseClick("left",$winxposition + .774 * $winwidth, $winyposition + .555 * $winheight)

Share this post


Link to post
Share on other sites
monoscout999

You can change the CoordMode to fit it to use the coords of the client window too.

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  

×

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.