Jump to content

Mouse Macros

I just got a new Logitech G203 mouse, and am trying to bind a macro to the forward side button. I need the macro to left-click three times. However, the macro recorder does not give me the option to bind mouse clicks as part of the macro. Is there anyway I can get it to record mouse clicks? if not, what is some third-party software I can use to do this

Link to comment
Share on other sites

Link to post
Share on other sites

14 hours ago, badreg said:

Autohotkey.

Thanks, this helps. I just have one issue. My macro doesn't appear to run correctly while the Shift or Ctrl keys are being pressed, and for my use case, I need it to work while those keys are being pressed. Any idea how to do this?

My code reads:

Xbutton2::
Click, 3

Link to comment
Share on other sites

Link to post
Share on other sites

5 hours ago, Flika1999 (Spooky edition) said:

Thanks, this helps. I just have one issue. My macro doesn't appear to run correctly while the Shift or Ctrl keys are being pressed, and for my use case, I need it to work while those keys are being pressed. Any idea how to do this?

My code reads:

Xbutton2::
Click, 3

Add a wildcard:

 

*Xbutton2::Click, 3

 

This will trigger the hotkey, no matter what other keys are pressed at the same time.

Link to comment
Share on other sites

Link to post
Share on other sites

20 hours ago, badreg said:

Add a wildcard:

 

 


*Xbutton2::Click, 3

 

 

This will trigger the hotkey, no matter what other keys are pressed at the same time.

Thanks, this has been so helpful. One more thing, how might I set it to delay each click in the macro by a few milliseconds? The SetMouseDelay feature hasn't worked for me, maybe I need to use a different command?

Link to comment
Share on other sites

Link to post
Share on other sites

On 7/5/2019 at 7:35 AM, Flika1999 (Spooky edition) said:

Thanks, this has been so helpful. One more thing, how might I set it to delay each click in the macro by a few milliseconds? The SetMouseDelay feature hasn't worked for me, maybe I need to use a different command?

If SetMouseDelay is unset, the default is 10 milliseconds, so declaring:

 

SetMouseDelay, 10

 

would have no effect. The "proper" solution would be to get SetMouseDelay working, but if you can't, the easy workaround is just to add a Sleep command between each click:

 

*Xbutton2::

Loop 3

Click

Sleep 20

Link to comment
Share on other sites

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

×