RadPanelBar Click event is not firing

6 posts, 0 answers
  1. Ravi
    Ravi avatar
    104 posts
    Member since:
    Oct 2012

    Posted 13 Jun 2011 Link to this post

     Hello,

    I am using Telerik PanelBar. I am using the version of 2010.3.1317.20. I cant upgrade to the latest version as the framework I am using .Net 2.0.

    I have added the PanelBar in the MasterPage, When i Click on any of the item in the panel bar, the Click event is not firing.

    The panelbar is populated at runtime. also the NavigateUri is set at runtime.

    <telerik:RadPanelBar runat="server" ID="RadPanelNavBar" Visible="false" ExpandMode="MultipleExpandedItems" 
                                            OnItemClick="RadPanelNavBar_ItemClick" EnableViewState="true">
                                    </telerik:RadPanelBar>

    the below code is how i am adding the RadPanelItems

    For Each mnuChildRow As DataRow In dtFilterData.Rows
                                    Dim menuAdminChild As New RadPanelItem()                                
                                    menuAdminChild.Text = mnuChildRow.Item(Field.DisplayName).ToString()
                                    menuAdminChild.NavigateUrl = "../" + mnuChildRow.Item(Field.ResourceName).ToString()
                                    menuMFGHeader.Items.Add(menuAdminChild)
                                Next

    The click event is below

    Protected Sub RadPanelNavBar_ItemClick(ByVal sender As Object, ByVal e As Telerik.Web.UI.RadPanelBarEventArgs) Handles RadPanelNavBar.ItemClick
            If e.Item.Items.Count > 0 Then
                If e.Item.Expanded = False Then
                    'Label1.Text = "Collapsed panel item - " + e.Item.Text
                Else
                    'Label1.Text = "Expanded panel item - " + e.Item.Text
                End If
            Else
                'Label1.Text = "Clicked panel item - " + e.Item.Text
            End If
        End Sub

    What finally i require is to have the RadPanelItem as selected on which the user last clicked. rest all remains un selected.

  2. Ravi
    Ravi avatar
    104 posts
    Member since:
    Oct 2012

    Posted 14 Jun 2011 Link to this post

    Appreciate your early response on this issue.

    Thanks,
  3. UI for ASP.NET Ajax is Ready for VS 2017
  4. Helen
    Admin
    Helen avatar
    1052 posts

    Posted 14 Jun 2011 Link to this post

    Hi David,

    Probably you will find helpful the following help topic:
    http://www.telerik.com/help/aspnet-ajax/menu-itemclick-event-not-fired.html

    Kind regards,
    Helen
    the Telerik team

    Browse the vast support resources we have to jump start your development with RadControls for ASP.NET AJAX. See how to integrate our AJAX controls seamlessly in SharePoint 2007/2010 visiting our common SharePoint portal.

  5. Ravi
    Ravi avatar
    104 posts
    Member since:
    Oct 2012

    Posted 22 Jun 2011 Link to this post

    I have RadPanelBar implemented in the MasterPage under "Is Not PostBack". When the user clicks the Rad Item the page is getting postback which is fine. but the master page IsPostBack is always false.

    Because of the above, I have two issues.

    1) The clicked panel item is not selected as the RadPanelBar is re-created again. the recreation is happening because IsPostBack is always false. IsPostback is becoming always false because the RadPanelItem have NavigateURL.

    2) There is Expand/Collapse button. each time the page is postback, and due to IsPostback is always false, the rad panel bar is re-created everytime. so if the user had collapsed few headers, then that is also not retained.

    Please let me know how to proceed in this scenario

    Thanks,
    Shiras
  6. Ravi
    Ravi avatar
    104 posts
    Member since:
    Oct 2012

    Posted 24 Jun 2011 Link to this post

    Appreciate your early response on this issues.

    Thanks
  7. Helen
    Admin
    Helen avatar
    1052 posts

    Posted 24 Jun 2011 Link to this post

    Hi David,

    Since your scenario is a bit complicated, could you please open a support ticket and send us a sample project which demonstrates the issue to examine it locally?

    Best wishes,
    Helen
    the Telerik team

    Browse the vast support resources we have to jump start your development with RadControls for ASP.NET AJAX. See how to integrate our AJAX controls seamlessly in SharePoint 2007/2010 visiting our common SharePoint portal.

Back to Top
UI for ASP.NET Ajax is Ready for VS 2017