View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Beto[_3_] Beto[_3_] is offline
external usenet poster
 
Posts: 140
Default How do I include a wider range in my code??

nrage21 < wrote:
Sub ZipCode()
If MyInput = "22222 to 99999" Then MsgBox "Area NOT covered",
vbOKOnly, "TRY AGAIN!"
End Sub


Replace MyInput = "22222 to 99999" with:

Val(Myinput) = 22222 And Val(MyInput) <= 99999

Regards,
--
Beto
Reply: Erase between the dot (inclusive) and the @.
Responder: Borra la frase obvia y el punto previo.