Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Hi,
I have a UserForm with many textboxes. the below Procedure is for the Unit Price Textbox. I put two restrictions on it, 1. to restrict blank entry 2. to restrict alphabatical entry both are working fine, but when I try to enter the value like 23.05 or 135.15 its not accepted. I mean the value in decimile its not accepting. Private Sub TxtUnitPrice_Exit(ByVal Cancel As MSForms.ReturnBoolean) ' to restrict blank entry If txtUnitPrice.Text = "" Then MsgBox "Sorry, please enter the Unit Price to proceed..." Cancel = True End If End Sub Private Sub txtUnitPrice_KeyPress(ByVal KeyAscii As MSForms.ReturnInteger) ' to restrict entry for Numbers only If KeyAscii < Asc("0") Or KeyAscii Asc("9") Then Interaction.Beep KeyAscii = 0 End If End Sub if anyone knows how to fix this problem. pls send me the solution, I will be highly appreciated...... Thanks and regards. Syed Shahzad Zafar Madinah |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
textbox problem | Excel Programming | |||
Textbox problem | Excel Programming | |||
Textbox Problem | Excel Programming | |||
Textbox problem | Excel Programming | |||
TextBox SetFocus Problem | Excel Programming |