Hello, HtmlForm frm = new HtmlForm(); pg.Controls.Add(frm); frm.Attributes.Add("runat", "server"); frm.Controls.Add(panelmain); pg.DesignerInitialize(); pg.RenderControl(htmlWrite); panelmain is asp:panel control which i need to print inside the panel.. This panel resides in child page (content place holder).. in this child page i am also using jquery datatable for search and filtering for gridview (gridview is inside the panel - so, i need to print panel) when i debug frm.Controls.Add(panelmain); , i am getting error error like follow Additional information: The Controls collection cannot be modified because the control contains code blocks (i.e. <% ... %>). But if i remove, the follow jquery datatable script, the print works. $('#<%=grdorders.ClientID%>').dataTable({ .. .. }); how to solve this problem?
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)