Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 258
Default Option Buttons

I have 3 option buttons on my userform:

No Lunch, 30 Minutes, 60 Minutes

I do not seem to know how to group these 3 buttons together so that I can
set 30 minutes as the default and selecting one of the others will clear the
default.


  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 47
Default Option Buttons

You ou can give the three buttons the same GroupName (in the Properties
window) or you can place them all in a Frame control. This ensures that only
one member can be selected. Change the Value property of the default button
to True.

--
John Green
Sydney
Australia


"Patrick Simonds" wrote in message
...
I have 3 option buttons on my userform:

No Lunch, 30 Minutes, 60 Minutes

I do not seem to know how to group these 3 buttons together so that I can
set 30 minutes as the default and selecting one of the others will clear

the
default.




  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 48
Default Option Buttons

Hi,

You need to set the value of the button to true.
IE: Userform1.Optionbutton2.value = True
You can use this code when you init. the userform.


"Patrick Simonds" wrote in message
...
I have 3 option buttons on my userform:

No Lunch, 30 Minutes, 60 Minutes

I do not seem to know how to group these 3 buttons together so that I can
set 30 minutes as the default and selecting one of the others will clear
the default.



  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 258
Default Option Buttons

Thanks guys for the quick response.

"Charles Harmon" wrote in message
...
Hi,

You need to set the value of the button to true.
IE: Userform1.Optionbutton2.value = True
You can use this code when you init. the userform.


"Patrick Simonds" wrote in message
...
I have 3 option buttons on my userform:

No Lunch, 30 Minutes, 60 Minutes

I do not seem to know how to group these 3 buttons together so that I can
set 30 minutes as the default and selecting one of the others will clear
the default.





  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 258
Default Option Buttons

Figured it out:

If OptionButton1.Value = True Then
rng(1, 12) = TimeSerial(0, 0, 0)

ElseIf OptionButton2.Value = True Then
rng(1, 12) = TimeSerial(0, 30, 0)

ElseIf OptionButton3.Value = True Then
rng(1, 12) = TimeSerial(0, 60, 0)
End If

"Patrick Simonds" wrote in message
...
Thanks guys for the quick response.

"Charles Harmon" wrote in message
...
Hi,

You need to set the value of the button to true.
IE: Userform1.Optionbutton2.value = True
You can use this code when you init. the userform.


"Patrick Simonds" wrote in message
...
I have 3 option buttons on my userform:

No Lunch, 30 Minutes, 60 Minutes

I do not seem to know how to group these 3 buttons together so that I
can set 30 minutes as the default and selecting one of the others will
clear the default.







Reply
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
Option Buttons/Radio Buttons John Calder New Users to Excel 7 May 16th 08 03:51 AM
Option Buttons Grant90 Excel Discussion (Misc queries) 1 July 29th 05 02:34 PM
yes/no option buttons Evanya Excel Discussion (Misc queries) 4 May 28th 05 12:19 AM
help with option buttons Vince Excel Programming 3 November 18th 04 10:54 PM
Option Buttons mudraker[_50_] Excel Programming 2 December 4th 03 01:44 AM


All times are GMT +1. The time now is 05:51 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"