+ Reply to Thread
Results 1 to 5 of 5

Controls in a Worksheet

  1. #1
    Jeff
    Guest

    Controls in a Worksheet

    Hello,

    What I would like to accomplish is to insert a "Frame" control & then add
    "Option buttons" to the Frame for the User to select & then with VBA to
    manipulate them.

    I first tried using the FORMS Toolbar controls. The work how ever u then
    have no control over them with VBA, or if u do I dont know how, perhaps
    someone can exlpain that to me, for example to make them Visible or not.

    Then I tried using the CONTROL TOOLBOX controls.
    With these u can control them with VBA. However,
    this for some reason doesnt have a "Frame" control, but I as able to add one
    by selecting the "More Controls" toolbar & then find the "Microsoft Forms 2.0
    Frame"
    When I add this "Frame" to my worksheet & then add the Option Button on top
    of the Frame, when I exit out of Design Mode the Option Buttons dissapear,
    sort of goes behind the Frame. The CONTROL TOOLBOX controls work for me
    better becuase then I can use VBA coding to manipulate them, but now I am
    experiencing the above problem. How can this be fixed ?

    Any help would be greatly appreciated.

    Thank you,
    Jeff

  2. #2
    Tom Ogilvy
    Guest

    Re: Controls in a Worksheet

    Frames from the msforms 2.0 library (control toolbox controls) do not work
    on an excel worksheet. Your first hint should have been that they do not
    appear on the control toolbox when the worksheet has the focus.

    --
    Regards,
    Tom Ogilvy

    "Jeff" <[email protected]> wrote in message
    news:[email protected]...
    > Hello,
    >
    > What I would like to accomplish is to insert a "Frame" control & then add
    > "Option buttons" to the Frame for the User to select & then with VBA to
    > manipulate them.
    >
    > I first tried using the FORMS Toolbar controls. The work how ever u then
    > have no control over them with VBA, or if u do I dont know how, perhaps
    > someone can exlpain that to me, for example to make them Visible or not.
    >
    > Then I tried using the CONTROL TOOLBOX controls.
    > With these u can control them with VBA. However,
    > this for some reason doesnt have a "Frame" control, but I as able to add

    one
    > by selecting the "More Controls" toolbar & then find the "Microsoft Forms

    2.0
    > Frame"
    > When I add this "Frame" to my worksheet & then add the Option Button on

    top
    > of the Frame, when I exit out of Design Mode the Option Buttons dissapear,
    > sort of goes behind the Frame. The CONTROL TOOLBOX controls work for me
    > better becuase then I can use VBA coding to manipulate them, but now I am
    > experiencing the above problem. How can this be fixed ?
    >
    > Any help would be greatly appreciated.
    >
    > Thank you,
    > Jeff




  3. #3
    Jeff
    Guest

    Re: Controls in a Worksheet

    Hi Tom,

    Than you, but do you have an answer as to how I can include a Frame & Option
    buttons on my worksheet that I can control with VBA ?

    Thank you,
    Jeff

    "Tom Ogilvy" wrote:

    > Frames from the msforms 2.0 library (control toolbox controls) do not work
    > on an excel worksheet. Your first hint should have been that they do not
    > appear on the control toolbox when the worksheet has the focus.
    >
    > --
    > Regards,
    > Tom Ogilvy
    >
    > "Jeff" <[email protected]> wrote in message
    > news:[email protected]...
    > > Hello,
    > >
    > > What I would like to accomplish is to insert a "Frame" control & then add
    > > "Option buttons" to the Frame for the User to select & then with VBA to
    > > manipulate them.
    > >
    > > I first tried using the FORMS Toolbar controls. The work how ever u then
    > > have no control over them with VBA, or if u do I dont know how, perhaps
    > > someone can exlpain that to me, for example to make them Visible or not.
    > >
    > > Then I tried using the CONTROL TOOLBOX controls.
    > > With these u can control them with VBA. However,
    > > this for some reason doesnt have a "Frame" control, but I as able to add

    > one
    > > by selecting the "More Controls" toolbar & then find the "Microsoft Forms

    > 2.0
    > > Frame"
    > > When I add this "Frame" to my worksheet & then add the Option Button on

    > top
    > > of the Frame, when I exit out of Design Mode the Option Buttons dissapear,
    > > sort of goes behind the Frame. The CONTROL TOOLBOX controls work for me
    > > better becuase then I can use VBA coding to manipulate them, but now I am
    > > experiencing the above problem. How can this be fixed ?
    > >
    > > Any help would be greatly appreciated.
    > >
    > > Thank you,
    > > Jeff

    >
    >
    >


  4. #4
    Dave Peterson
    Guest

    Re: Controls in a Worksheet

    You can control the optionbuttons from the forms toolbar in VBA.

    Dim myOptBtn As OptionButton
    Set myOptBtn = ActiveSheet.OptionButtons("option button 1")
    With myOptBtn
    .Value = xlOn 'xloff
    .Visible = True
    .Caption = "hi there"
    End With



    Jeff wrote:
    >
    > Hello,
    >
    > What I would like to accomplish is to insert a "Frame" control & then add
    > "Option buttons" to the Frame for the User to select & then with VBA to
    > manipulate them.
    >
    > I first tried using the FORMS Toolbar controls. The work how ever u then
    > have no control over them with VBA, or if u do I dont know how, perhaps
    > someone can exlpain that to me, for example to make them Visible or not.
    >
    > Then I tried using the CONTROL TOOLBOX controls.
    > With these u can control them with VBA. However,
    > this for some reason doesnt have a "Frame" control, but I as able to add one
    > by selecting the "More Controls" toolbar & then find the "Microsoft Forms 2.0
    > Frame"
    > When I add this "Frame" to my worksheet & then add the Option Button on top
    > of the Frame, when I exit out of Design Mode the Option Buttons dissapear,
    > sort of goes behind the Frame. The CONTROL TOOLBOX controls work for me
    > better becuase then I can use VBA coding to manipulate them, but now I am
    > experiencing the above problem. How can this be fixed ?
    >
    > Any help would be greatly appreciated.
    >
    > Thank you,
    > Jeff


    --

    Dave Peterson

  5. #5
    Tom Ogilvy
    Guest

    Re: Controls in a Worksheet

    What are you trying to achieve with the Frame. If you want to use it to
    group the option buttons, just use the groupname property. Assign any name
    as long as it is common to the optionbuttons in the group.

    --
    Regards,
    Tom Ogilvy

    "Jeff" <[email protected]> wrote in message
    news:[email protected]...
    > Hi Tom,
    >
    > Than you, but do you have an answer as to how I can include a Frame &

    Option
    > buttons on my worksheet that I can control with VBA ?
    >
    > Thank you,
    > Jeff
    >
    > "Tom Ogilvy" wrote:
    >
    > > Frames from the msforms 2.0 library (control toolbox controls) do not

    work
    > > on an excel worksheet. Your first hint should have been that they do

    not
    > > appear on the control toolbox when the worksheet has the focus.
    > >
    > > --
    > > Regards,
    > > Tom Ogilvy
    > >
    > > "Jeff" <[email protected]> wrote in message
    > > news:[email protected]...
    > > > Hello,
    > > >
    > > > What I would like to accomplish is to insert a "Frame" control & then

    add
    > > > "Option buttons" to the Frame for the User to select & then with VBA

    to
    > > > manipulate them.
    > > >
    > > > I first tried using the FORMS Toolbar controls. The work how ever u

    then
    > > > have no control over them with VBA, or if u do I dont know how,

    perhaps
    > > > someone can exlpain that to me, for example to make them Visible or

    not.
    > > >
    > > > Then I tried using the CONTROL TOOLBOX controls.
    > > > With these u can control them with VBA. However,
    > > > this for some reason doesnt have a "Frame" control, but I as able to

    add
    > > one
    > > > by selecting the "More Controls" toolbar & then find the "Microsoft

    Forms
    > > 2.0
    > > > Frame"
    > > > When I add this "Frame" to my worksheet & then add the Option Button

    on
    > > top
    > > > of the Frame, when I exit out of Design Mode the Option Buttons

    dissapear,
    > > > sort of goes behind the Frame. The CONTROL TOOLBOX controls work for

    me
    > > > better becuase then I can use VBA coding to manipulate them, but now I

    am
    > > > experiencing the above problem. How can this be fixed ?
    > > >
    > > > Any help would be greatly appreciated.
    > > >
    > > > Thank you,
    > > > Jeff

    > >
    > >
    > >




+ 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