Expand group programatically

6 posts, 0 answers
  1. Bob
    Bob  avatar
    2 posts
    Member since:
    Dec 2008

    Posted 13 Aug 2009 Link to this post

    Hi Guys

    Can anyone tell me how to expand a given group in a panelbar and call PerformClick on a given RadButtonElement?

    Thanks in advance
  2. Boyko Markov
    Admin
    Boyko Markov avatar
    610 posts

    Posted 13 Aug 2009 Link to this post

    Hello Bob ,

    To expand a group programatically you can use the Expanded property of RadPanelBarGroupElement. For example:

     this.radPanelBarGroupElement1.Expanded = true;

    If you need more information, please write us back.

    Kind regards,
    Boyko Markov
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Check out the tips for optimizing your support resource searches.
  3. UI for WinForms is Visual Studio 2017 Ready
  4. Jay Jose
    Jay Jose avatar
    13 posts
    Member since:
    Jul 2009

    Posted 09 Sep 2009 Link to this post

    Hi,

    I build my panelbar programmatically and I want to expand the groupelement when displayed.

    I tried this:

    this.radPanelBarGroupElement1.Expanded = true;

    but it did not work.

    Any more ideas?

    Thanks,
    Jay



  5. Jay Jose
    Jay Jose avatar
    13 posts
    Member since:
    Jul 2009

    Posted 09 Sep 2009 Link to this post

    Hi,

    Kindly disregard my previous post, I already got the solution.

    grpElement.ShowChildren(true);
    grpElement.Expanded = true;

    Thanks,
    Jay
  6. Bob
    Bob  avatar
    2 posts
    Member since:
    Dec 2008

    Posted 10 Sep 2009 Link to this post

    Hi Jay

    It seems to depend on the Groupstyle property. I resolved my problem by  setting

    radGroupABC.Selected = true;

    I did this after it had been added to the panel bar.

    Hope that helps.

    Bob Bailey
  7. Boyko Markov
    Admin
    Boyko Markov avatar
    610 posts

    Posted 11 Sep 2009 Link to this post

    Hello Bob ,

    RadPanelBarGroupElement Expanded property purpose is to expand or collapse the group where the Selected property selects or deselects the group. When the panel bar is in OutlookStyle, you should use the Selected property instead of the Expanded property if you want to make active a particular group element. In all other cases you should use the Expanded property. Another important thing is that you should use these properties when the RadPanelBarGroupElement is part of the elements tree i.e it should be added to the items collection of RadPanelBar.

    Best wishes,
    Boyko Markov
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
Back to Top
UI for WinForms is Visual Studio 2017 Ready