I have a simple textbox that processes the KeyDown event so that when the user hits the 'Enter' key it performs the necessary function. My question is, it makes a beep sound when you hit 'Enter' and process the event. Can I get rid of this beep sound somehow?
Thanks,
-bitwise
FYI, HERE IS THE CODE:
Private Sub TextBoxDeposits_KeyDown(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyEventArgs) Handles TextBoxDeposits.KeyDown
If TextBoxDeposits.Text <> [String].Empty Then
If e.KeyCode = Keys.Enter Then
Dim decCurDeposit As Decimal
Dim strCurDeposit As String
decCurDeposit = CDec(TextBoxDeposits.Text)
strCurDeposit = decCurDeposit.ToString("c")
myDeposits = myDeposits + decCurDeposit
LabelTotal.Text = myDeposits.ToString("c")
ListBoxDeposits.Items.Add(strCurDeposit)
TextBoxDeposits.Text = ""
e.Handled = True
End If
End If
End Sub
Thanks,
-bitwise
FYI, HERE IS THE CODE:
Private Sub TextBoxDeposits_KeyDown(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyEventArgs) Handles TextBoxDeposits.KeyDown
If TextBoxDeposits.Text <> [String].Empty Then
If e.KeyCode = Keys.Enter Then
Dim decCurDeposit As Decimal
Dim strCurDeposit As String
decCurDeposit = CDec(TextBoxDeposits.Text)
strCurDeposit = decCurDeposit.ToString("c")
myDeposits = myDeposits + decCurDeposit
LabelTotal.Text = myDeposits.ToString("c")
ListBoxDeposits.Items.Add(strCurDeposit)
TextBoxDeposits.Text = ""
e.Handled = True
End If
End If
End Sub