Sunday, August 2, 2009

How can I make a text box in VISUAL BASIC ignore spaces and special characters?

I need to do this without entering all the special characters into the program. Is there a shortcut or somthing that can help me do this?

How can I make a text box in VISUAL BASIC ignore spaces and special characters?
Look into the the following events for the textbox :





KeyDown


KeyPress


KeyUp





See the following link and how to manipulate these events to your specs. You will also need a hex/dec/ascii chart. Search the web for that, although I do believe s space char is ascii 20.





Link : http://msdn.microsoft.com/library/defaul...





Just program for the char range you need to use A-Z(Ascii 65-90) and a-z(Ascii 97-122) and 0-9(Ascii 48-57), everything else set to KeyCode = 0 (nothing).








Good luck!
Reply:its a program for programming, u have to put the special characters for programming


No comments:

Post a Comment