Is this for a Windows Form? If so .NET 2.0 brought back the masked text box which can only allow numerics if you set that property but you can also just validate the text after the fact. A better way to do this on your own would be to use the textbox's KeyPress event or something along those lines and look at the following.
If e.KeyChar = Chr(CharCode for 0-9) Then
e.Handled = True
Else
e.Handled = False
End If
I think that is all you really need to do. -- modified at 12:10 Tuesday 29th May, 2007
CleaKO
"Now, a man would have opened both gates, driven through and not bothered to close either gate." - Marc Clifton (The Lounge)