<asp:GridView ID="grdUploadedFiles" runat="server" AutoGenerateColumns="False" AllowPaging="True"
PageSize="7" DataKeyNames="ID" OnRowEditing="grdUploadedFiles_RowEditing" OnRowUpdating="grdUploadedFiles_RowUpdating"
OnRowCancelingEdit="grdUploadedFiles_RowCancelingEdit" OnRowDeleting="grdUploadedFiles_RowDeleting"
ShowFooter="True" ForeColor="Black" GridLines="Vertical"
Width="439px" BackColor="White" BorderColor="#999999" BorderStyle="Solid"
Font-Size="Small" Font-Names="Arial" CellPadding="3" BorderWidth="1px">
<Columns>
<asp:TemplateField HeaderText="Type" HeaderStyle-HorizontalAlign="Center" >
<ItemTemplate>
<asp:Label ID="lblType" runat="server" Text='<%# Bind("FileType") %>'></asp:Label>
</ItemTemplate>
<asp:CommandField ShowEditButton="True">
<ItemStyle/>
</asp:CommandField></column></gridview>
I am using above code for my gridview.and i want to give padding to my 1st column.and also i want to give underline to my edit and delete link in my gridview.For that if i give textuderline=’true” on editing it shows Update Delete both a single underline which looks ugly.
Is there any other way?
I will suggest using CSS selectors for styling instead of using control properties (that generates inline styling that are difficult to maintain/change) – assuming you have applied css class “myGridView” to your grid view then use CSS such as