get the windows hotkey instead of the ahk one Topic is solved

Get help with using AutoHotkey (v1.1 and older) and its commands and hotkeys
rexey
Posts: 11
Joined: 21 Jul 2017, 14:32

get the windows hotkey instead of the ahk one

22 Jul 2017, 11:18

hi,

what i mean by this strange title is :
is there a simple way to get in a variable an hotkey in windows style ( like ctrl + shift + A ) instead of the ahk style ( ^+A)
so i can use it in a gui to show the user the chosen hotkey

i'm not asking for a full code, but just where to look or if there is a really simple way to do that that i don't know about.
User avatar
Capn Odin
Posts: 1352
Joined: 23 Feb 2016, 19:45
Location: Denmark
Contact:

Re: get the windows hotkey instead of the ahk one  Topic is solved

22 Jul 2017, 13:30

Code: Select all

keyCombi := "^!Delete"

Gui, Add, Hotkey, vChosenHotkey

Gui, Show, AutoSize
return

q::GuiControl, , ChosenHotkey, % keyCombi
or

Code: Select all

keyCombi := "^!Delete"

MsgBox, % RegExReplace(SubStr(str := StrReplace(StrReplace(StrReplace(keyCombi, "^", " Ctrl "), "!", " Alt "), "+", " Shift "), 2, StrLen(str) - 1), "\s+", " + ")
Please excuse my spelling I am dyslexic.
rexey
Posts: 11
Joined: 21 Jul 2017, 14:32

Re: get the windows hotkey instead of the ahk one

22 Jul 2017, 14:44

thanks ! the strReplace function is exactly what i need.

Return to “Ask for Help (v1)”

Who is online

Users browsing this forum: No registered users and 181 guests