Sign in to follow this  
Followers 0
niceguy75

Mouse Coords are not working properly in classic theme

5 posts in this topic

#1 ·  Posted (edited)

Hi guys,

I am writing a spript for chaning boot animation in windows 7 I am using "MouseClick" command in my script but when the theme changes from aero to Classic the "MouseClick" commands are not working properly.

I have also used "Opt("MouseCoordMode", 0)" command but still mouse coords are not working properly. Please help me guys, please explain considering me a newbie. I am not a expert when it comes to writing scripts in autoit.

Thanks in advance.

Edited by niceguy75

Share this post


Link to post
Share on other sites



I think I might be having a similar issue. Mine is with Server '08 though. I have all these scripts that will do precise mouse clicks for check boxes, but in Server 08 it will click below the check boxes. I'm guessing it has to do with the title bar being slightly different, the x value is upheld correctly, but the y coord seems to make it click too low. Sorry to say, but from what I can tell the title is effecting the mouse coords, even after setting it to be relative.

Perhaps this is a bug with autoit, perhaps the "relative to window" mode should be consistent while using any size or shape of title bar/theme/etc.

Share this post


Link to post
Share on other sites

Perhaps this is a bug with autoit, perhaps the "relative to window" mode should be consistent while using any size or shape of title bar/theme/etc.

It is not a bug, having window-coords not work on window-coords would to be insane. Also you want client-coords, so stop messing with window-coords!

:huh2:

Share this post


Link to post
Share on other sites

It is not a bug, having window-coords not work on window-coords would to be insane. Also you want client-coords, so stop messing with window-coords!

:huh2:

I am not aware of client-coords, as I am a newbie when it comes to autoit scripts, here is my a portion of my script with mouse coords will you please guide how can I use client-coords in place of "mouseclick".

Run("C:\Appz\Boot\Win7BootUpdater.exe")
Opt("MouseCoordMode", 0)
WinWait("Windows 7 Boot Updater","Animation")
If Not WinActive("Windows 7 Boot Updater","Animation") Then WinActivate("Windows 7 Boot Updater","Animation")
WinWaitActive("Windows 7 Boot Updater","Animation")
WinMove("Windows 7 Boot Updater","", 0, 0)
MouseClick("left", 145, 35)
MouseClick("left", 145, 85)
MouseClick("left", 145, 125)
MouseClick("left", 145, 170)

Share this post


Link to post
Share on other sites

So set MouseCoordMode to 2, and recheck with Au3Info that you have the actual client-coordinates (the same way you checked window-coords, Options>Coord Mode>Client) and work from there.

And as i told wesleyb, try to avoid MouseClick() if possible (for reasons like these). Look at ControlClick() and it's brethren to automate controls directly.

And no, I don't have Windows 7 Boot Updater so I Can't help more than this.

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