1
Reply

Disable a GridView, but enable a template field column

Dhilipkumar r

Dhilipkumar r

Mar 11 2017 2:14 PM
347
Hi,
Is it possible to disable a gridview and enable a templatefield inside a column?
  1. grdEmployee.Enabled=false;  
and which contains a template field of linkbuttons
  1. <asp:TemplateField HeaderText="Branch">  
  2.     <EditItemTemplate>  
  3.         <asp:TextBox ID="txtBranch" runat="server" Text='<% Bind("Branch") %>' />  
  4.     </EditItemTemplate>  
  5.     <ItemTemplate>  
  6.         <asp:LinkButton ID="lnkBranch" runat="server" Text='<% Bind("Branch") %>' OnClientClick="openPopupWindow()" />  
  7.     </ItemTemplate>
  8. </asp:TemplateField>
  But whenever I disable the gridview, the linkbutton disappears and the column appears as plain text. I want to disable the gridview but not the linkbutton template field column
Thanks in advance 

Answers (1)