|
-
Nov 3rd, 2000, 12:27 AM
#1
Thread Starter
Lively Member
I was just wondering why the Delete key (DEL) works in text boxes...... but the Backspace key does not..
Is there anyway to enable the backspace key in textboxes, or make it work?
I don't see a backspace key reference on the ASCII chart I have..
Thanks for any info 
-
Nov 3rd, 2000, 12:37 AM
#2
Frenzied Member
Harry.
"From one thing, know ten thousand things."
-
Nov 3rd, 2000, 01:02 AM
#3
Thread Starter
Lively Member
Ack! I figured out why - but not how to fix it!
I'm using a "NON-Number-key" filter on all the textboxes:
Private Sub GameMax_KeyPress(KeyAscii As Integer)
If IsNumeric(Chr(KeyAscii)) <> True Then KeyAscii = 0
End Sub
How could I check for a backspace keypress to fix this?
-
Nov 3rd, 2000, 06:08 AM
#4
The backspace is ASCII character 8. Use a select case instead:
Code:
Select Case KeyAscii
Case 48 To 57 'Numbers
Case 8 ' Backspace
Case 10 'Linefeed
Case 13 'Carriage return
Case Else
KeyAscii = 0
End Select
- gaffa
-
Nov 3rd, 2000, 09:01 AM
#5
Thread Starter
Lively Member
Thanks.... Thants new to me.
Works great
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
|