Go Back   Computer Forums > General Computing > Programming
Click Here to Login
Join Computer forums Today

Thread Tools Search this Thread Display Modes
Old 04-21-2013, 09:35 PM   #1
Baseband Member
Join Date: Jan 2013
Location: Canada
Posts: 69
Default KeyDown event not found in VB.NET 2010?

Hai everyone, I've been trying to look at how games and other such applications are made in VB.NET 2010 and they all, of course, use the keydown and keyup events, but when I take a look at VB.NET on my computer I dont seem to have those events, is there something additional i need to install? Thanks to anyone who can give me a hand.

jaywash is offline   Reply With Quote
Old 04-22-2013, 11:54 AM   #2
Site Team
root's Avatar
Join Date: Mar 2004
Posts: 8,107
Default Re: KeyDown event not found in VB.NET 2010?

There are probably much better ways of doing what you're doing than using raw input.

I mean your window will have focus whilst the person is playing the game, and there would be no other reason that your "games" should want to deal with raw input and capture keystrokes when the game should be in the back ground. or be... I don't know, windowless so that a user doesn't know that the "game" is running...

anyway, the INPUT and KEYDOWN functions are not in standard libraries at all which is why yu don't have those events, they are messages from a raw input buffer. the raw input buffer captures the events, and tells your program that it has these events

you should tailor your google searches toward capturing raw data, you need to tell your program to register it's interest in raw data using RID flags, then use getrawinputdata functions. these are functions of the standard windows library.

As you may have guessed from my initial paragraph, there is little use for capturing raw input inside making games, it's far more likely that this is the sort of thing that you'd be interested in if you were making a key logger.

for that reason, it's pretty unlikely that there are going to be floods of people wanting to help.
but that does give you another avenue of searching, if you can find and understand the source code for a key logger, then you'll be a big step forward to using raw keystroke data in your game.
I didn’t fight my way to the top of the food chain to be a vegetarian…
Im sick of people saying 'dont waste paper'. If trees wanted to live, they'd all carry guns.
"The inherent vice of capitalism is the unequal sharing of blessings; The inherent vice of socialism is the equal sharing of miseries."
root is offline   Reply With Quote

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off

All times are GMT -5. The time now is 06:01 PM.

Powered by vBulletin® Version 3.8.8 Beta 4
Copyright ©2000 - 2020, vBulletin Solutions, Inc.
Search Engine Friendly URLs by vBSEO 3.6.0