Disable ‘Beep’ in Textbox when pressing the ‘Enter’ Key – VB.NET 2008/2010, VB 2013

Click Star to Rate Post
1 Star2 Stars3 Stars4 Stars5 Stars (5 votes, average: 5.00 out of 5)
 

This will stop that beep from sounding when you press the Enter key in the textbox or combobox control. This works for VB 2005, VB 2008, Visual Basic 2010, and VB 2013.

Just put the code in the Textbox _KeyDown event.

        '
        'This code will disable the ‘Beeping’ you get when you press the ‘Enter’ key in a
        'Textbox control. This code needs to go into the Textbox_KeyDown’ event.
        '
        If e.KeyCode = Keys.Enter Then

            e.SuppressKeyPress = True

        End If

 

One thought on “Disable ‘Beep’ in Textbox when pressing the ‘Enter’ Key – VB.NET 2008/2010, VB 2013

  1. pankaj c

    i have problem in insert query in visual basic , so at a time more than one form(data) add in database table,so please i want quiry of insert command

    Reply

Leave a Reply

Your email address will not be published.