I've been having quite a rough time trying to figure out how to map hotkeys to left alt, right alt, left control and right control keys.
First, I did thisCode:Case Keys.ControlKey My.Computer.Audio.Play(My.Resources.Who_are_you_2, AudioPlayMode.Background) End SelectAnd they worked perfectly fine, HOWEVER I am only able to map the hotkeys to 2 basic keys. Control and Alt, meaning what the left and right alt keys COULD do, will only do 1 task, which isn't very satisfying for what I'm trying to create.Code:Case Keys.Menu My.Computer.Audio.Play(My.Resources.Who_are_you_2, AudioPlayMode.Background) End Select
After I had some trouble, I searched up "Key Enumerations System Keys"
https://msdn.microsoft.com/en-us/lib...v=vs.110).aspx
And sure enough, the keys I wanted existed, and upon discovering those keys, I looked at them in Visual Basic, and they too, existed. When I started tampering with it, to use left alt, right alt, etc, etc I only found out, that the keys did absolutely nothing, the tasks were not started.
These are the codes I tried, all of them do absolutely nothing at all
Code:Case Keys.RControlKey My.Computer.Audio.Play(My.Resources.Who_are_you_2, AudioPlayMode.Background) End SelectCode:Case Keys.LControlKey My.Computer.Audio.Play(My.Resources.Who_are_you_2, AudioPlayMode.Background) End SelectCode:Case Keys.LMenu My.Computer.Audio.Play(My.Resources.Who_are_you_2, AudioPlayMode.Background) End SelectCode:Case Keys.RMenu My.Computer.Audio.Play(My.Resources.Who_are_you_2, AudioPlayMode.Background) End SelectThanks for helping me, I really appreciate it!








Reply With Quote
