+ Reply to Thread
Results 1 to 3 of 3

deselect all option buttons in a frame

Hybrid View

  1. #1
    Registered User
    Join Date
    11-28-2003
    Posts
    39

    deselect all option buttons in a frame

    I'm half way there with this.

    From the top.
    I have the below code which tags the value of frame1 as row1, Ok so far.
    Now the bit i'm stuck at. Then i want to make all the optionbuttons in frame1 false.


    Dim MyMike
    row1 = Val(Frame1.Tag)
    If row1 <> IsNull(MyMike) Then
    row1 = False
    End If

  2. #2
    Tom Ogilvy
    Guest

    Re: deselect all option buttons in a frame

    Dim ctrl as Control
    for each ctrl in Userform1.Frame1.Controls
    if typeof ctrl is MSForms.OptionButton then
    ctrl.Value = False
    end if
    Next

    IsNull doesn't test if a variable is empty. Use isEmpty


    --
    Regards,
    Tom Ogilvy

    "mikewild2000" <mikewild2000.23hbha_1140357001.3242@excelforum-nospam.com>
    wrote in message
    news:mikewild2000.23hbha_1140357001.3242@excelforum-nospam.com...
    >
    > I'm half way there with this.
    >
    > From the top.
    > I have the below code which tags the value of frame1 as row1, Ok so
    > far.
    > Now the bit i'm stuck at. Then i want to make all the optionbuttons in
    > frame1 false.
    >
    >
    > Dim MyMike
    > row1 = Val(Frame1.Tag)
    > If row1 <> IsNull(MyMike) Then
    > row1 = False
    > End If
    >
    >
    > --
    > mikewild2000
    > ------------------------------------------------------------------------
    > mikewild2000's Profile:

    http://www.excelforum.com/member.php...fo&userid=3276
    > View this thread: http://www.excelforum.com/showthread...hreadid=514129
    >




  3. #3
    Registered User
    Join Date
    11-28-2003
    Posts
    39
    thank you tom for your expert help.

    I never thought of that method.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

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

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1