title: How to set the width of TemplateField column in Grid view?
body: <p>Hi I am developing a website using c# and asp.net. But my grid view is not showing properly for one page only. Whether I am using the same css class but still the output is something odd.</p>
  
  <p>Here is the output I am getting:</p>
  
  <p><img src="https://i.stack.imgur.com/mYOox.jpg" alt="enter image description here"></p>
  
  <p>here is my design view code for the grid:</p>
  
  <pre><code>     &lt;div style="width: 800px; align-content: center;"&gt;
  
      &lt;asp:GridView ID="gvMv" runat="server" AutoGenerateColumns="False" width="400px"
          OnRowDataBound="gvMv_RowDataBound" CssClass="Grid" ShowFooter="True"&gt;
          &lt;FooterStyle Height="25" /&gt;
          &lt;RowStyle /&gt;
          &lt;PagerStyle /&gt;
          &lt;HeaderStyle /&gt;
          &lt;Columns&gt;
              &lt;asp:BoundField DataField="day" HeaderText="Day" HeaderStyle-Width="150" ItemStyle-Height="25" HeaderStyle-Height="30"&gt;
  
                  &lt;HeaderStyle Height="30px" Width="150px"&gt;&lt;/HeaderStyle&gt;
  
                  &lt;ItemStyle Height="25px"&gt;&lt;/ItemStyle&gt;
  
              &lt;/asp:BoundField&gt;
              &lt;asp:TemplateField HeaderText="0.30"&gt;&lt;/asp:TemplateField&gt;
  
              &lt;asp:TemplateField HeaderText="1.00"&gt;&lt;/asp:TemplateField&gt;
              &lt;asp:TemplateField HeaderText="2.00"&gt;&lt;/asp:TemplateField&gt;
              &lt;asp:TemplateField HeaderText="2.50"&gt;&lt;/asp:TemplateField&gt;
  
              &lt;asp:TemplateField HeaderText="4.00"&gt;&lt;/asp:TemplateField&gt;
              &lt;asp:TemplateField HeaderText="5.00"&gt;&lt;/asp:TemplateField&gt;
  
              &lt;asp:TemplateField HeaderText="1.50"&gt;&lt;/asp:TemplateField&gt;
              &lt;asp:TemplateField HeaderText="Total" ItemStyle-ForeColor="#0099FF"&gt;
                  &lt;ItemStyle ForeColor="#0099FF"&gt;&lt;/ItemStyle&gt;
              &lt;/asp:TemplateField&gt;
  
  
          &lt;/Columns&gt;
          &lt;PagerStyle BackColor="#2461BF" ForeColor="White" HorizontalAlign="Center" Font-Size="Smaller" /&gt;
          &lt;RowStyle CssClass="rSty" BackColor="#F7F7DE" /&gt;
          &lt;SelectedRowStyle BackColor="#CE5D5A" Font-Bold="true" ForeColor="White" /&gt;
          &lt;PagerStyle BackColor="#F7F7DE" ForeColor="Black" HorizontalAlign="Right" /&gt;
          &lt;HeaderStyle CssClass="hSty" BackColor="#6B696B" Font-Bold="True" ForeColor="White" /&gt;
          &lt;AlternatingRowStyle BackColor="White" /&gt;
      &lt;/asp:GridView&gt;
  
    &lt;/div&gt;
  </code></pre>
  
  <p>I want all of the column to be same width. Can anyone please help me on this?</p>
  
  <p>Thank you.</p>