Get the expanded/collapsed status of PanelBar rootitems, to process server-side

Thread is closed for posting
4 posts, 0 answers
  1. 580CD692-028C-4E24-BE30-7082BF6FA598
    580CD692-028C-4E24-BE30-7082BF6FA598 avatar
    168 posts
    Member since:
    Nov 2006

    Posted 05 Jan 2007 Link to this post

    Requirements

    r.a.d.controls version

    RadPanelBar 4.0.3            

    .NET version

    ASP.NET 2.0

    Visual Studio version

    2005

    programming language

    VB.NET & JavaScript

    browser support

    all browsers supported by r.a.d.controls


     
    PROJECT DESCRIPTION
    Here is a method to determine the status of a RadPanelBar RootItem (expanded/collapsed), so you can process it server-side, like saving it to a database or cookie as a user preference.

    Step 1 - create a .aspx webpage
    Step 2 - Add a RadPanelBar, you can fill the PanelBar manually or programmatically
    Step 3 - Add a button
    Step 4 - Add a javascript function EnumeratePanelBarRootItems() to the bottom of the webpage. When the button is clicked, this javascript code gets the statusses of the rootitems and puts them in the hidden fields
    Step 5 - In the Page_Load of the code-behind file, create the hidden form fields
    Step 6 - In the Page_Load, add a javascript attribute to the Click event of the button
    Step 7 - In the Butoon_Click event, put the code that gets the values of the hidden fields and puts them in label, or if you want a database or cookie.

    Good luck!

  2. 300D5976-BFAC-4403-937D-074AFC183EE2
    300D5976-BFAC-4403-937D-074AFC183EE2 avatar
    4281 posts
    Member since:
    Sep 2012

    Posted 08 Jan 2007 Link to this post

    Hello Johan,

    Thank you for your submission - your telerik points have been updated.

    Sincerely yours,
    Paul
    the telerik team
  3. 08C37E6A-4852-4441-9F92-3316ACE7CD64
    08C37E6A-4852-4441-9F92-3316ACE7CD64 avatar
    73 posts
    Member since:
    Mar 2008

    Posted 07 May 2008 Link to this post

    Hello,

    I realize this post is over a year old.  However, I believe I am trying to accomplish what your solution provides.

    My goal is to maintain the panelbar status when a link has been selected that essentially reloads a new page.  I want those items that were open to still be expanded, and those that were not open to be collapsed.

    I see other posts about populating Session values.  Do you have an opinion as to what works best?

    Cheers,

    Doug
  4. 0A60E00F-83B0-4846-A3BC-422B3C1FC63B
    0A60E00F-83B0-4846-A3BC-422B3C1FC63B avatar
    1 posts
    Member since:
    Jun 2008

    Posted 23 Jun 2008 Link to this post

    I am in the same situation as Doug. Any update to this?
Back to Top

This Code Library is part of the product documentation and subject to the respective product license agreement.