Jump to content

how to hotkey + # ^


jennico
 Share

Recommended Posts

i am completely confused because i can't get it going: hotkeying "+","#","^".

i tried everything (even hex and vk_codes):

HotKeySet("a","alpha")
HotKeySet("{+}","plus")
HotKeySet("{ASC 043}","plus2")
$x=Chr(43)
HotKeySet("{"&$x&"}","plus3")
HotKeySet($x,"plus4")
HotKeySet("{#}","cross")
HotKeySet("{^}","circumflex")
HotKeySet("<","smaller")
HotKeySet(">","bigger")
HotKeySet("!<","bigger")

While 1
    GUIGetMsg()
WEnd

Func alpha()
    MsgBox(0,"","a")
EndFunc

Func plus()
    MsgBox(0,"","+")
EndFunc

Func plus2()
    MsgBox(0,"","+2")
EndFunc

Func plus3()
    MsgBox(0,"","+3")
EndFunc

Func plus4()
    MsgBox(0,"","+4")
EndFunc

Func cross()
    MsgBox(0,"","#")
EndFunc

Func circumflex()
    MsgBox(0,"","^")
EndFunc

Func smaller()
    MsgBox(0,"","<")
EndFunc

Func bigger()
    MsgBox(0,"",">")
EndFunc

so why not possible ?

thank you very much

Spoiler

I actively support Wikileaks | Freedom for Julian Assange ! | Defend freedom of speech ! | Fight censorship ! | I will not silence.OixB7.jpgDon't forget this IP: 213.251.145.96

 

Link to comment
Share on other sites

Probably not what you want to hear..

On most standard keyboards to type the + you would press Shift and Equal keys to type + symbol

So in reality you can't press the plus key without first pressing the shift key. (with the exception of Num Pad + key of coarse)

So wouldn't it just be easy to use HotKeySet("+=","plus")?

Same thing goes for the other keys such as:

"#" would be HotKeySet("+3","cross")

"^" would be HotKeySet("+6","circumflex")

Cheers

Edit:

HotKeySet("{ESC}","Esc")
HotKeySet("+=","plus")
HotKeySet("+3","cross")
HotKeySet("+6","circumflex")
HotKeySet("+,","smaller")
HotKeySet("+.","bigger")

While 1
    Sleep(100)
WEnd

Func plus()
    MsgBox(0,"","+", 1)
EndFunc

Func cross()
    MsgBox(0,"","#", 1)
EndFunc

Func circumflex()
    MsgBox(0,"","^", 1)
EndFunc

Func smaller()
    MsgBox(0,"","<", 1)
EndFunc

Func bigger()
    MsgBox(0,"",">", 1)
EndFunc

Func Esc()
    Exit
EndFunc
Edited by smashly
Link to comment
Share on other sites

thanx

of course i read the sendkeylist.

Send Command (if zero flag) Resulting Keypress

{!} !

{#} #

{+} +

{^} ^

the problem is, send() works fine with + # ^, while hotkeyset() does not. why the difference ?

my keyboard is a German one, and the three keys + # ^ are unshifted, while ! is shifted and makes no problem hotkeying it. that's the problem.

so anyone has an idea ? maybe double-shifting ? modifying the modifier keys ? using the MapVirtualKeyEx Function ? does this make sense ? anyone who has experiences in that ?

j.

edit:

- _ispressed does not do it, because still passes the keypress

- wm_keydown with guiregister does not work globally and not with editboxes

There is a suggestion to the autoit team: change the modifiers !^+# to chars which can internationally be used ! why not ABCD for example ? they can easily be hotkeyed by +a +b +c +d and still be used as modifiers.

or maybe S=shift A=alt C=ctrl W=win ?

this would be a nice tribute to foreign kblayouts !

edit:

maybe it is possible to modify these modifiers manually ? how ?

edit:

maybe one of the developers can give me the api call scource of hotkeypress ? so i can try to modify it. unfortunately it is not in the "included" section. this would be easy.

j

Edited by jennico
Spoiler

I actively support Wikileaks | Freedom for Julian Assange ! | Defend freedom of speech ! | Fight censorship ! | I will not silence.OixB7.jpgDon't forget this IP: 213.251.145.96

 

Link to comment
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
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...