Home |
Search |
Today's Posts |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Bob,
The code would need to check for decimal points as well as number keypad usage, so it would need three more cases: period, number keypad numbers, and number keypad decimal. Bernie Here is a textbox event that only allows numeric input Private Sub TextBox1_KeyPress(ByVal KeyAscii As MSForms.ReturnInteger) Select Case KeyAscii Case 48 To 57 'Nos 0 - 9 Exit Sub Case 32 ' space Case Else Application.EnableEvents = False KeyAscii = 0 Application.EnableEvents = True Beep End Select End Sub |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Textboxes | Excel Discussion (Misc queries) | |||
Looping through textboxes | Excel Discussion (Misc queries) | |||
tab between several textboxes | Excel Worksheet Functions | |||
Excel Textboxes | Excel Programming | |||
userform textboxes again | Excel Programming |