|
-
Sep 29th, 2003, 11:27 AM
#1
Thread Starter
Member
Key Supression
I have a combobox that I want the user to be able to type into and then press enter to call a method. My only problem is that when the user presses enter, a *ding* noise plays. I have tried setting 'e.handled = true' but that is not working for some reason. Does anyone have any ideas on getting rid of the *ding*?
Thanks!
-
Sep 29th, 2003, 12:06 PM
#2
Sleep mode
Try this
VB Code:
Private Sub ComboBox1_KeyPress(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles
ComboBox1.KeyPress
If Asc(e.KeyChar()) = 13 Then
e.Handled = True
End If
End Sub
-
Sep 29th, 2003, 12:26 PM
#3
Thread Starter
Member
Nope. Still same problem.
-
Sep 29th, 2003, 12:35 PM
#4
-
Sep 29th, 2003, 12:40 PM
#5
Thread Starter
Member
Does another property need to be set somewhere first?
-
Sep 29th, 2003, 12:55 PM
#6
Sleep mode
Originally posted by Cmathis
Does another property need to be set somewhere first?
no , just throw a combobox and add that code in the Keypress event .
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
|