Hello sir,
i want to add scroll with fixed header in gridview below is my code:
<div class="fontInside" style="height:300px; background-color:#eeeeee; overflow:scroll;border:1px; border-color:#d4d4d4 ;border-collapse:collapse; width:100%">
<asp:GridView ID="gvAccounts" runat="server"
CssClass="mGrid" AutoGenerateColumns="False"
GridLines="None" >
<AlternatingRowStyle CssClass="alt" />
<HeaderStyle CssClass="fontInside"/>
<EmptyDataTemplate>
<asp:Label ID="lblEmptySearch" runat="server">No Account Found</asp:Label>
</EmptyDataTemplate>
<Columns>
<asp:TemplateField HeaderText="Company" HeaderStyle-Width="250px" ItemStyle-CssClass="fontInside">
<ItemTemplate>
<a href='<%#"BasicCompanyHome.aspx?CompanyName="+DataBinder.Eval(Container.DataItem,"CompanyName")+"&CompanyID="+DataBinder.Eval(Container.DataItem,"Company_Id")%>' target="_blank" style="color:#0681ab; text-decoration:none"><%#Eval("CompanyName")%></a>
</ItemTemplate>
</asp:TemplateField>
<asp:BoundField DataField="Phone_No" HeaderText="Phone" ItemStyle-CssClass="fontInside"/>
<asp:BoundField DataField="Revenue" HeaderText="Revenue" ItemStyle-CssClass="fontInside" />
<asp:BoundField DataField="Employees" HeaderText="Employees" ItemStyle-CssClass="fontInside" />
<asp:BoundField DataField="All_Industries" HeaderText="Industry" ItemStyle-CssClass="fontInside"/>
<asp:BoundField DataField="All_Countries" HeaderText="Country" ItemStyle-CssClass="fontInside" />
<asp:BoundField DataField="Status" HeaderText="Status" ItemStyle-CssClass="fontInside"/>
<asp:BoundField DataField="SetRemainder" HeaderText="Alert" ItemStyle-CssClass="fontInside" />
</Columns>
</asp:GridView>
</div>