|
-
December 21st, 2005, 08:20 AM
#1
KeyAscii
Hello.If somebody know's the KeyAscii for PageUp and PageDown please mail me to: [email protected], thanks.
-
December 21st, 2005, 08:31 AM
#2
Re: KeyAscii
 Originally Posted by mainar
Hello.If somebody know's the KeyAscii for PageUp and PageDown please mail me to.
PageUp- 33
Pagedown - 34
Remember you cannot trap these keys in KeyPress Event. You will either have to use KeyUp or KeyDown Event.
And don't put your emailId out here.
-
December 21st, 2005, 09:10 AM
#3
Re: KeyAscii
If you want to find any keyAscii value just place in the keypress event on a form or object the following code.
Code:
Text1.Text = KeyAscii
Then everytime you press a key the textbox will display the value of that key.
Rich
-
December 21st, 2005, 09:27 AM
#4
Re: KeyAscii
 Originally Posted by Rich2189
If you want to find any keyAscii value just place in the keypress event on a form or object the following code.
Code:
Text1.Text = KeyAscii
Then everytime you press a key the textbox will display the value of that key.
Rich
That wouldn't work, since Page Up and Page Down do not have ASCII values.
In VB, they do have key codes (designated as 33 for vbKeyPageUp and 34 for vbKeyPageDown), so you can check for them in KeyUp and KeyDown events, but not in KeyPress events.
You can also find other keys (like Shift, Caps Lock, Home, End, Insert, Delete, all the Function keys, and so on) only through KeyUp and KeyDown, since they don't have ASCII values.
-
December 21st, 2005, 09:33 AM
#5
Re: KeyAscii
i feel like a dunce now, im doing KeyAscii in college at the moment, of course it doesnt have a value, thanks chaos, now i know how to get the arrow keys to work 
Rich
-
December 21st, 2005, 10:43 AM
#6
Re: KeyAscii
Another great way to get ascii key values... use the VB constants
i.e.
vbKeyPageDown, vbKeyPageUp, vbKeyF1 etc etc etc
Mike
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|