Page 1 of 1

Simulate Sequential Keys to New Hotkey

Posted: 09 Jun 2019, 18:21
by radar81
I'd like to create a script that simulates this key combination:

Left Alt, v, t, b (pressed sequentially, not simultaneously)

I'd like to map that to a Hotkey such as Ctrl+Y

Please advise, thanks

Re: Simulate Sequential Keys to New Hotkey

Posted: 09 Jun 2019, 19:12
by YoucefHam
try this

Code: Select all

^y::
KeyWait, Ctrl
Sleep, 60
SendInput, {LAlt}
Sleep, 60
SendInput, {v}
Sleep, 60
SendInput, {t}
Sleep, 60
SendInput, {b}
return
if you are goining to select a menu Item use
WinMenuSelectItem

Re: Simulate Sequential Keys to New Hotkey

Posted: 10 Jun 2019, 11:01
by radar81
Works perfectly thanks! :bravo:

Incidentally, I am using this to Toggle the display of the Firefox bookmarks toolbar on/off. Hope it helps somebody else.