LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #8   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 81
Default Which button was pressed?

Yo,

puting

Me.Hide

in the ok buttons click event will hide the userform, but, and i'm
not sure i full understand what you are try to do, that not so good
for you, becasue you want to do diffrent things based on the choice
made on the userform,

Try this way:

some code to open the user form

YourFormName.Show

Now the form is open. It has all the option you might need on it. The
user chech on box or option and click ok.

now you must tell the programe what to do, based on what the user has
clicked so..

OKbutton_click

if optionbox1.value=true then
NameOfYourSubToGoTOIfThisCondtionIsPicked
elseif
AnotherSub
Else if

etc etc

'''Now close you form.

me.close

end sub


next time you open this form the last check box will still be checked,
but the sub will not run unless the user pressess OK


Good Luck

ROss
 
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
create a button when pressed it will +1 to another field mswisher Excel Discussion (Misc queries) 2 November 24th 09 04:34 PM
Enter button jumps to next cell each time its pressed!!!! evasmagacz Excel Discussion (Misc queries) 3 June 17th 07 08:37 PM
preventing button being pressed Mike Excel Discussion (Misc queries) 2 March 16th 06 03:47 PM
count how many times a button is pressed Mike Excel Discussion (Misc queries) 2 February 5th 06 09:38 PM
Errormessage when button is pressed twice or more Pointerman Excel Programming 4 April 7th 04 03:56 PM


All times are GMT +1. The time now is 01:17 AM.

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

About Us

"It's about Microsoft Excel"