Jump to content
Xtreme .Net Talk

Recommended Posts

Posted

HI ALL:

 

In my application, I need to restrict the user to enter the keyboard input to the combo box.

 

when i was working in vb6 i had used the code:

 

keyascii=0 in keypress event of combo box

 

How can i acheive for vb.net combo box

 

thanks in advance

Posted

I think you're looking for:

 

e.Handled = True

 

(e is the event args object of the event)

 

...which essentially cancels the event (the key press). Any code you have in the event will execute, but they key press is surpressed.

 

Paul

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...