RadPanelBar - how to unselect item

5 posts, 0 answers
  1. Frank
    Frank avatar
    6 posts
    Member since:
    Feb 2009

    Posted 21 Mar 2009 Link to this post

    I am trying to unselect the current selected item of the RadPanelBar inside the code. I set the RadPanelBar selected item to false but the highlighted grey color is still appearing. It seems to me that RadPanelBar does not get updated via ajax.I am assuming. In asp.net, I wrap the control with asp:updatepanel and in the code do Update(); and Bind();

    Does any know how I do this with Telerik? ..or please let me know if my approach is incorrect. Thanks for any feedbacks.

    -----------------sample code--------------------------
    //Get RadPanelBar

    RadPanelBar

     

    radpanelbar= (RadPanelBar) folderExplorer.FindControl("RadPanelBar1");
    //Unselected so that the highlighted color will disappear

     

     

    radpanelbar.SelectedItem = false;

     

     

    radpanelbar.DataBind();

     

  2. SamJ
    SamJ avatar
    101 posts
    Member since:
    Jul 2008

    Posted 22 Mar 2009 Link to this post

    Hi Frank,

    Are you using RadAjaxManager or RadAjaxPanel to ajaxify the page?
    If using the RadAjaxManager, you just need to add an ajax setting where the RadPanelBar updates itself:

    <telerik:RadAjaxManager ID="RadAjaxManager1" runat="server"
       <AjaxSettings> 
           <telerik:AjaxSetting AjaxControlID="RadPanelBar1"
               <UpdatedControls> 
                    <telerik:AjaxUpdatedControl ControlID="RadPanelBar1"
                    </telerik:AjaxUpdatedControl> 
               </UpdatedControls> 
           </telerik:AjaxSetting> 
       </AjaxSettin> 
    </telerik:RadAjaxManager> 

    RadAjaxManager
    RadAjaxPanel

    I hope this can give the right direction.

    SamJ


  3. Pablo
    Pablo avatar
    5 posts
    Member since:
    Oct 2010

    Posted 24 Oct 2010 Link to this post

    I have the same problem, but I have the RadPanelBar within a usercontrol (ascx). Within a ItemTemplate of RadPanelBar is a radTreeView. The radTreeView updated only if it is postback.

    Thanks for your help.
  4. Iana Tsolova
    Admin
    Iana Tsolova avatar
    3388 posts

    Posted 25 Oct 2010 Link to this post

    Hello Pablo,

    Can you elaborate a bit on your scenario? Does the TreeView updates properly on the server but the changes are not applied properly when the page renders? Do you have an ajax setting where the RadPanelBar is added as updated control?

    Regards,
    Iana
    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
  5. Pablo
    Pablo avatar
    5 posts
    Member since:
    Oct 2010

    Posted 25 Oct 2010 Link to this post

    The Problem is resolved. I was referencing using RadAjax.Net2 controls and Telerik.Web.UI in my solution. Does not fail, but it seems that there are problems in using them at the same time.
    Thanks for everything.
Back to Top