change keystroke as I press the mouse button?

x64 Replacement/Alternative to Microsoft's IntelliMouse application.
Forum rules
Please read the forum rules before posting for the first time.
The more information you can provide, the quicker and more accurately someone can help.
NOTE: To reduce spam, new users can not post links or images until they have at least 4 posts.
Post Reply
ddoggg
New User
Posts: 1
Joined: Sun Jul 21, 2019 4:12 pm

change keystroke as I press the mouse button?

Post by ddoggg » Sun Jul 21, 2019 4:30 pm

Wondering if I can make a macro like this with xmouse button.
When I press the button, It Press "A" , if I press the same button again , it will be "B"
And it will reset every 2.2 seconds.

Thanks

User avatar
Kukurykus
Fanatic
Posts: 248
Joined: Sat Jul 02, 2016 1:15 pm

Re: change keystroke as I press the mouse button?

Post by Kukurykus » Sun Jul 21, 2019 4:35 pm

HAMA Roma, Rapoo 3920P
Windows 10 x64, Intel i5-4670K @ 3.40GHz, 8GB,
Intel(R) HD Graphics 4600, Intel SSD 179 GB HDD

User avatar
phil
Site Admin
Posts: 5997
Joined: Sun Apr 06, 2003 11:12 pm

Re: change keystroke as I press the mouse button?

Post by phil » Tue Jul 23, 2019 8:10 am

You may be able to do this with XMBC (although Autohotkey will be more powerful and probably reliable).
But i XMBC use simulated keystrokes, for the button on layer 1, use simulated keystrokes and type A{layer2}
For the same button on layer 2, use simulated keys and type B
On layer 2, set the option to "Switch to" layer 1 after 2 seconds (note: you cant specify in milliseconds here I'm afraid, so 2.2 seconds is out.)
You may be also able to type B{WAITMS2200}{layer1} on layer 2's simkeys. It also depends on if you want the key held down or simply pressed and released (play around with the send method in the simkeys dialog).
--[ Phil ]--
--[ Administrator & XMBC Author ]--
Logitech G9, Logitech MX518, Microsoft Intellimouse, Trust 16341 BT Mouse
Windows 10 x64, Intel i5-9600k, Asus Z390-ROG, 16GB DDR4,
nVidia GeForce GTX 970, Evo 970 500Gb NVME, 2x2TB WD Black (RAID1)

User avatar
Kukurykus
Fanatic
Posts: 248
Joined: Sat Jul 02, 2016 1:15 pm

Re: change keystroke as I press the mouse button?

Post by Kukurykus » Tue Jul 23, 2019 11:12 am

You are right, it's possible to do with XMBC to some degree. I read too fast and seen 'button' word as a key in my mind so I thought it's another post someone wants XMBC to react for keyboard as well.
HAMA Roma, Rapoo 3920P
Windows 10 x64, Intel i5-4670K @ 3.40GHz, 8GB,
Intel(R) HD Graphics 4600, Intel SSD 179 GB HDD

Post Reply