Error Checking in Excel
Thanks Thanks:  0
Likes Likes:  0
Results 1 to 9 of 9

Thread: How do you group option buttons

  1. #1
    Guest

    Default

    How do you group option buttons from the forms toolbar, I have put them in group boxes but when I change the cell link on one they all change, I want to have two groups on one page linked to different cells. thanks

  2. #2
    MrExcel MVP Anne Troy's Avatar
    Join Date
    Feb 2002
    Location
    Westwood NJ
    Posts
    2,582
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    The whole idea of grouped option buttons is that the user can only choose one. i.e., What town do you live in? There is only ONE answer. Hence, you only need one cell to contain that value.

    Perhaps that sheds some light for you?
    ~Anne Troy

  3. #3
    Guest

    Default

    But I want to have two sets of buttons link to different cells total independent of the other ones, can this be done?

  4. #4
    MrExcel MVP lenze's Avatar
    Join Date
    Feb 2002
    Location
    Helena, MT
    Posts
    13,690
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    You can do this by grouping them in frames. The thing to be careful about, is the option buttons must be entirely inside the frames If any part is outside the frame, the grouping will fail. Also, once an option box has been group and associated, it sometimes will not take a change. You may need to delete it and insert a new one.

  5. #5
    Guest

    Default

    How do you insert frames?

  6. #6
    MrExcel MVP
    Join Date
    Feb 2002
    Location
    Sunny, spring-like Hull
    Posts
    3,339
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    There should be a frame icon in the VB toolbox (just to the left of the command button in mine). In VB6 you need to draw (or cut and paste) option buttons directly onto the frame (ie not dragged on from the userform), so I presume the same is true of Excel VBA.

  7. #7
    MrExcel MVP lenze's Avatar
    Join Date
    Feb 2002
    Location
    Helena, MT
    Posts
    13,690
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    On the Form Toolbar, it is refered to as a Group Box

  8. #8
    MrExcel MVP
    Join Date
    Feb 2002
    Location
    Sunny, spring-like Hull
    Posts
    3,339
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    Sorry, I didn't realise you were putting these onto a worksheet, frames don't appear in the sheet toolbox, you need to click on the More controls button at the bottom and go down to Microsoft Forms 2.0 Frame. Draw your frame, then right click on it in design mode and choose Frame Object- Edit to show the VBA toolobox. Draw your Option buttons onto the frame. You will need a separate frame for each group of buttons.

  9. #9
    Guest

    Default

    Thanks I had them in a group box but part of the button must have been outside the frame.

Some videos you may like

User Tag List

Like this thread? Share it with others

Like this thread? Share it with others

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •