This is a migrated thread and some comments may be shown as answers.

Radpanel itemclick - reloads entire page

1 Answer 65 Views
This is a migrated thread and some comments may be shown as answers.
Top achievements
Rank 1
PV asked on 22 Oct 2010, 01:22 PM
Hello Team,

I have a Radpanelbar on a aspx and 5 items, and when clicked on item, a usercontrol is displayed in the div (that is made visible in the event OnItemClick).

The issue that is occuring is, when I click on one item, the entire is refreshed and all the usercontrol's pageload event is fired on the page.

I am looking at an approach where only the one user control to be loaded on click of one item instead of entire page refresh.

Radpanel looks like:

<telerik:RadPanelBar ID="pnlNav" runat="server" Width="180" OnItemClick="pnlNav_ItemClick"
                        EnableEmbeddedSkins="false" >
                            <telerik:RadPanelItem Text="UserControl1" Value="UserControl1" Expanded="true"
                                PreventCollapse="true" ExpandedImageUrl="">
                            <telerik:RadPanelItem Text="UserControl2" BackColor="#608DC8" Value="UserControl2" />
                            <telerik:RadPanelItem Text="UserControl3" Value="UserControl3" />
                            <telerik:RadPanelItem Text="UserControl4" Value="UserControl4" />

 protected void pnlNav_ItemClick(object sender, RadPanelBarEventArgs e)

 switch (e.Item.Value)

                case "UserControl1":
                    this.UserControl1.Visible = true;
                case "UserControl2":
                    this.divUserControl1.Visible = true;
                    this.ucUserControl1.Load();//public method
                case "UserControl3":
                  ----//same code
                case "UserControl4":
                   same code

Please provide any pointers if i am missing anything

1 Answer, 1 is accepted

Sort by
Nikolay Tsenkov
Telerik team
answered on 27 Oct 2010, 11:34 AM
Hello PV,

My suggestion would be to use RadAjaxManager.
Here is a reference for it in our help documentation:
Here is the first of many demo's in in the section for RadControls for ASP.NET AJAX:

Hope this is going to help you!

Nikolay Tsenkov
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
Asked by
Top achievements
Rank 1
Answers by
Nikolay Tsenkov
Telerik team
Share this question