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!