this topic on the very first page of VB section.. why asking again dude?
https://www.mpgh.net/forum/33-visual-...p-hotkeys.html
Complete this:
Label1.text = ( whatever button i just pressed ) ?
Eg, if i pressed F6, The label text would be " F6 "
this topic on the very first page of VB section.. why asking again dude?
https://www.mpgh.net/forum/33-visual-...p-hotkeys.html
Light travels faster than sound. That's why most people seem bright until you hear them speak.
learn hotkeys then'll be easy there's lot of TUTs
I need a code..I Am a complete newb. :P
YouTube - Broadcast Yourself. you'll get code for sure, its pretty long/yea
dude.. its all about events... you should really try to do it yourself.. Search around MSDN for returns and use intellisense to find functions, proprieties.. etc.
Light travels faster than sound. That's why most people seem bright until you hear them speak.
OMG!
I KNOW HOW DO HOTKEYS, THATS NOT WHAT IM LOOKING FOR!!!!!!
Right
When you are making the settings for a game
it will say
Shoot : [ Left Mouse ]
Then you click it
Shoot : [ ]
Then you put what you want the shoot button to be
Shoot : [ F Key ]
It detects which key you just pressed..
I Want a label to detect which key i pressed and then tell me.
.......Ok, watch the rage.
Next on the list, what everyone is saying is correct, You just not getting it.
But....there is an easier way
really all you want to do is use keydown (keeping in mind that in the Keydown Event
e = System.Windows.Forms.KeyEvenArgs (KeyEvents)
go online and look up the "KeyCode:Private Sub Form1_KeyDown(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyEventArgs) Handles MyBase.KeyDown If e.KeyCode = 37 Then label1.text = "cursor left" end if If e.KeyCode = 39 Then ' Cursor right label1.text = "cursor right" end if End Sub
Enumeration" list.
----
e.Key = Key.Return etc.
Last edited by NextGen1; 07-27-2010 at 11:13 PM.
[php]If getasynckeystate(keys.f6) then
label1.text = "F6"
End if[/php]
I just did that for 240 keys not gonna give you though, it takes some time. I don't support copy & paste. You better use select case though.
We do know what you want and with the information given above you can figure it out.
Or you convert the key pressed to string, google for a method.
Last edited by Blubb1337; 07-27-2010 at 11:17 PM.
Problem is, i am doing this becuase i bought a USB game controller off ebay, i need to make sure the buttons work, and the buttons are called Button1, Button 2, that kind of thing..
Just go into a game and check it out x.x