Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Hi
Look at this: Sub aaa() a = InputBox("Enter a value or text") If a = "" Then MsgBox ("No entry, or Cancel") If IsNumeric(a) Then msg = MsgBox("Number") Else MsgBox ("Text") End If End Sub Regards, Per "Alfredo_CPA" .(donotspam) skrev i meddelelsen ... Hi, Does anybody knows how to instruct VBA to diferentiate between a Cancel in the InputBox and a cero entered in the impiut box? (excel 2003) I have this code: ElseIf myerrorvalue = False Then Exit Sub '(errorvalue is the result of the inputbox) VBA is taking a 0 (cero) value as False (just like if the user click the cancel button) and exits the sub, but I need the code to keep going Thanks |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
InputBox Cancel event | Excel Programming | |||
InputBox Cancel event | Excel Programming | |||
InputBox Cancel Button | Excel Programming | |||
Doing nothing when pressing Cancel on InputBox | Excel Programming | |||
InputBox: Separate CANCEL and 0 | Excel Programming |