Private Sub textBox1_Change()
On Error Resume Next
If TextBox1 = "" Then Exit Sub
If Not IsNumeric(Right(TextBox1, 1)) Then
If Right(TextBox1, 1) = "." Then
MsgBox "Le caractere saisi n'est pas valide"
TextBox1 = Left(TextBox1, Len(TextBox1) - 1)
End If
End If
End Sub