Hi
I am trying to widen my first template field to 600 as shown below but the field seems to <HeaderStyle Width="600px" />
remain the same narrow size
<asp:GridView ID="GridView_Questions" runat="server" BackColor="White"
BorderColor="#3366CC" BorderStyle="Solid" BorderWidth="1px" CellPadding="4"
Height="147px" Visible="False" Width="795px">
<Columns>
<asp:TemplateField HeaderText="Question">
</asp:TemplateField>
I also tried the following which didn't work either
<asp:GridView ID="GridView_Questions" runat="server" BackColor="White"
BorderColor="#3366CC" BorderStyle="Solid" BorderWidth="1px" CellPadding="4"
Height="147px" Visible="False" Width="795px">
<Columns>
<asp:TemplateField HeaderText="Question" ControlStyle-Height="220"
ControlStyle-Width="700">
<ControlStyle Height="220px" Width="700px" />
<HeaderStyle HorizontalAlign="Left" />
</asp:TemplateField>
<asp:GridView CellPadding="5" AutoGenerateColumns="False
BorderStyle="Solid" BorderWidth="1" ForeColor="#333333" Font-Names="Verdana"
EnableSortingAndPagingCall
<PagerSettings Position="TopAndBottom" PageButtonCount="20" />
<RowStyle BackColor="#ffffff" BorderStyle="Solid" BorderWidth="1px" BorderColor="Black" Font-Size="10px" />
<AlternatingRowStyle BackColor="#e8e8e8" HorizontalAlign="Left" />
<FooterStyle BackColor="#6699FF" Font-Bold="True" ForeColor="White" />
<PagerStyle BackColor="White" ForeColor="Black" Font-Bold="True" />
<HeaderStyle BackColor="#DCEDE5" ForeColor="Black" Font-Size="10px"/>
<FooterStyle BackColor="#DCEDE5" ForeColor="Black" Font-Size="11px" Font-Bold="True"/>
<EditRowStyle BackColor="#FFFF99" ForeColor="Black" Font-Bold="True" />
<EmptyDataTemplate>
<center> -- No Records Found -- </center>
</EmptyDataTemplate>
</asp:GridView>
However I have a few properties in my CSS file that didn't seem to work in the .skin file:
.gridview
{
font-size:0.75em;
width:90%;
}
.gridview tr
{
font-size:0.95em;
height:auto;
}
.gridview td
{
font-size:1.15em;
}
.gridview caption
{
text-align:left;
font-size:0.85em;
font-weight:bold;
font-family: Verdana, Geneva, Arial, Helvetica, sans-serif;
padding: 2px;
color:Black;
background-color: #DCEDE5;
border:solid 1px black;
}