LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 55
Default vbCancel

Greetings !

I have an InputBox.

How do I distinguish between a valid input value of 2 and
the user clicking on the "Cancel" button ?

This worked just FINE - until I entered a value of 2 !

Ans = InputBox( _
"Enter a value between 1 and 5, myTitle, TP)
If Ans = vbCancel Then Exit Sub
TP = Ans


 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
EXIT SUB UPON VBCANCEL FARAZ QURESHI Excel Discussion (Misc queries) 2 April 9th 09 12:38 PM


All times are GMT +1. The time now is 07:42 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"