I have 64 textboxes on a userform. I want to restrict input to numeric values only. Have found some code that works as follows:
Public Sub TextBox1_KeyPress (ByVal KeyAscii As MSForms.ReturnInteger)
Select Case KeyAscii
Case Asc("0") To Asc("9")
Case Else
KeyAscii = 0
End Select
End Sub
Question is how can this code be writen without having to create 64 entries?
Any help much appreciated.
Cheers
PeterT
Bookmarks