RadPanelBar for ASP.NET

Enumerate the panel items Send comments on this topic.
Telerik RadPanelBar client-side > Enumerate the panel items

Glossary Item Box

You can enumerate all items in the PanelBar instance using the EnumerateAllItems() method. To enumerate only root items, use the Items collection of the PanelBar, or the Items collection of the respective parent item.

Examples:

Enumerate root items

  Copy Code
<script type="text/javascript">
   
function EnumerateRootItems()
       {
       
var PanelBar = <%= RadPanelBar1.ClientID %>;
        
for (var i=0; i<PanelBar.Items.length; i++)
           {
              
alert(PanelBar.Items[i].Text);
           }
       }
</script>


Enumerate all items

  Copy Code
<script type="text/javascript">

   
function EnumerateAllItems()
      {
       
var PanelBar = <%= RadPanelBar1.ClientID %>;
        
for (var i=0; i<PanelBar.AllItems.length; i++)
           {
              
alert(PanelBar.AllItems[i].Text);
           }
      }
</script>