Find control inside the NestedTableView in client side

1 posts, 0 answers
  1. Rishi
    Rishi avatar
    43 posts
    Member since:
    Feb 2010

    Posted 07 Sep 2017 Link to this post

    Hi 

     

    I am trying to find a control like a label inside the nestedtable view in the client side when a button on the parent table is clicked. Can you please direct me to how get it.

     

    This is how far I got :-

    function showDetailsOnButtonClick(rowIndex) {
            var parentRow = $find("<%=rGridColors.ClientID %>").get_masterTableView().get_dataItems()[rowIndex];
            var lblInNestedTableView = parentRow .get_dataItems()[0].findControl("lblInNestedTableView");
             lblInNestedTableView .visible = false;
            }

     

    Here is the markup :-

     <telerik:RadGrid runat="server" ID="rGridColors" >

               <MasterTableView AutoGenerateColumns="false" AllowPaging="false"  HierarchyDefaultExpanded="true" CssClass="grid">
                    <Columns>
                     
                        <telerik:GridTemplateColumn HeaderText="Color" UniqueName="Color">
                       <ItemTemplate>
                     
    <asp:ImageButton ID="btnShowColorLabel" runat="server" ImageUrl="~\images/info.gif"/>
    </span>
                       </ItemTemplate>
                        </telerik:GridTemplateColumn>
                       
                    </Columns>
               
                <NestedViewTemplate>

             <asp:Label runat="server" id ="lblInNestedTableView" Text ="You CLicked on color :===" />

     

     

    Thanks

     

Back to Top