Jump to content

Recommended Posts

Posted (edited)

Could you please show me or refer me to the documents how to do these things:

  • Remap the {LEFT CLICK} to letter A.
  • Remap the {RIGHT CLICK} to letter B.
  • Remap the {MIDDLE CLICK} to letter C.
  • Remap every single {SCROLL UP} to number 1.
  • Remap every single {SCROLL DOWN} to number 2.

It looks like it's hard to remap the mouse' elements..    :sweating:

Edited by Servant
Posted

Can you please tell us what you need this for? Just for educational reasons or do you want to solve a real problem?

My UDFs and Tutorials:

Spoiler

UDFs:
Active Directory (NEW 2024-07-28 - Version 1.6.3.0) - Download - General Help & Support - Example Scripts - Wiki
ExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example Scripts
OutlookEX (2021-11-16 - Version 1.7.0.0) - Download - General Help & Support - Example Scripts - Wiki
OutlookEX_GUI (2021-04-13 - Version 1.4.0.0) - Download
Outlook Tools (2019-07-22 - Version 0.6.0.0) - Download - General Help & Support - Wiki
PowerPoint (2021-08-31 - Version 1.5.0.0) - Download - General Help & Support - Example Scripts - Wiki
Task Scheduler (2022-07-28 - Version 1.6.0.1) - Download - General Help & Support - Wiki

Standard UDFs:
Excel - Example Scripts - Wiki
Word - Wiki

Tutorials:
ADO - Wiki
WebDriver - Wiki

 

Posted

Can you please tell us what you need this for? Just for educational reasons or do you want to solve a real problem?

Just forget about the mouse scroll.. For now, I just want to remap the right mouse button to the "A" key.

If I get this, I'll also get how to remap the left mouse button and the middle mouse button..

Posted

Thanks for the reply, but it doesn't really answer my question ;)

My UDFs and Tutorials:

Spoiler

UDFs:
Active Directory (NEW 2024-07-28 - Version 1.6.3.0) - Download - General Help & Support - Example Scripts - Wiki
ExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example Scripts
OutlookEX (2021-11-16 - Version 1.7.0.0) - Download - General Help & Support - Example Scripts - Wiki
OutlookEX_GUI (2021-04-13 - Version 1.4.0.0) - Download
Outlook Tools (2019-07-22 - Version 0.6.0.0) - Download - General Help & Support - Wiki
PowerPoint (2021-08-31 - Version 1.5.0.0) - Download - General Help & Support - Example Scripts - Wiki
Task Scheduler (2022-07-28 - Version 1.6.0.1) - Download - General Help & Support - Wiki

Standard UDFs:
Excel - Example Scripts - Wiki
Word - Wiki

Tutorials:
ADO - Wiki
WebDriver - Wiki

 

Posted (edited)

I GET IT!!

#include <Misc.au3>
#include "MouseOnEvent.au3"

Func bigA()
   Send("A")
EndFunc

_MouseSetOnEvent($MOUSE_SECONDARYUP_EVENT, "__Dummy", 0, 1)
_MouseSetOnEvent($MOUSE_SECONDARYDOWN_EVENT, "__ADummy", 0, 1)

; Idle
While 1
   _MouseSetOnEvent($MOUSE_SECONDARYDOWN_EVENT, "bigA") ; Secondary mouse button down.
   if _IsPressed("1B") Then ExitLoop
   Sleep(10)
Wend

_MouseSetOnEvent($MOUSE_SECONDARYUP_EVENT)
_MouseSetOnEvent($MOUSE_SECONDARYDOWN_EVENT)

You just need to include the "MouseOnEvent.au3" at >MouseOnEvent UDF! - Example Scripts - AutoIt Forums.

 

But it's a little bit of slow when I try to repeatedly right clicking even though I remove the Sleep(10).

Edited by Servant

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
×
×
  • Create New...