You are not logged in.

Dear visitor, welcome to Jabaco - Community. If this is your first visit here, please read the Help. It explains in detail how this page works. To use all features of this page, you should consider registering. Please use the registration form, to register here or read more information about the registration process. If you are already registered, please login here.

IsoCAM

Beginner

  • "IsoCAM" started this thread

Posts: 2

Date of registration: Jun 19th 2011

  • Send private message

1

Sunday, June 19th 2011, 8:44pm

Textbox - Preventing some characters from being input

Hi,

I have a textbox that Iwant to prevent some characters from not being input (%, $, @, #, ? etc)

Can anybody tell me how to do tis in Jabaco.

My Visual Basic code is....

Private Sub Text1_KeyPress(KeyAscii As Integer)
KeyAscii = Asc(Chr$(KeyAscii))

If KeyAscii < 48 Then If KeyAscii <> 45 Then If KeyAscii <> 8 Then KeyAscii = 0
If KeyAscii = 91 Then KeyAscii = 0
If KeyAscii > 58 Then If KeyAscii < 65 Then KeyAscii = 0
If KeyAscii > 92 Then If KeyAscii < 97 Then KeyAscii = 0
If KeyAscii > 122 Then KeyAscii = 0
End Sub

Many thanks in advance!!!!

IsoCAM

Rate this thread
WoltLab Burning Board