I have a TextBox control called TextBoxTotal on my form. When I try and run the program, I get the following error:
"Procedure declaration does not match description of event or procedure having the same name"
Here is the sub in question
Private Sub TextBoxTotal_KeyPress(KeyAscii As Integer)
Select Case KeyAscii
Case 48 To 57
'Ok to type these keys
Case Else
KeyAscii = 0
End Select
End Sub
Something else curious, if I rename the sub to Text1_KeyPress the error goes away, but the sub never gets called. (I have no TextBox called Text1 defined on the form)
Any ideas?
Thanks,
Tim
"Procedure declaration does not match description of event or procedure having the same name"
Here is the sub in question
Private Sub TextBoxTotal_KeyPress(KeyAscii As Integer)
Select Case KeyAscii
Case 48 To 57
'Ok to type these keys
Case Else
KeyAscii = 0
End Select
End Sub
Something else curious, if I rename the sub to Text1_KeyPress the error goes away, but the sub never gets called. (I have no TextBox called Text1 defined on the form)
Any ideas?
Thanks,
Tim