Danke für die Hilfe.
Gruss Oli
Private Sub TextBox1_KeyPress(ByVal KeyAscii As MSForms.ReturnInteger)
Select Case KeyAscii
Case Asc("0") To Asc("9")
Case Asc(","), Asc(".")
If InStr(TextBox1, ".") <> 0 Then
KeyAscii = 0
Else
KeyAscii = Asc(".")
End If
Case Asc(vbBack)
Case Asc("-")
If Len(TextBox1) = 0 Then
If InStr(TextBox1, "-") <> 0 Then
Else
KeyAscii = Asc("-")
End If
Else
KeyAscii = 0
End If
Case Else
KeyAscii = 0
End Select
End Sub