Monday, 12 June 2017

Text Box - Numeric Value

Private Sub TbCastingWt_KeyPress(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles TbCastingWt.KeyPress
        If Asc(e.KeyChar) <> 13 And Asc(e.KeyChar) <> 8 And Asc(e.KeyChar) <> 46 And Not IsNumeric(e.KeyChar) Then
            e.Handled = True
        End If
    End Sub

No comments:

Post a Comment