如何控制gridview的整体宽度
gridview在设计视图中固定好宽度后,浏览时就会变宽,这要怎么办?请各位大侠帮忙解决,不胜感激!<asp:GridViewID="gvList"runat="serv...
gridview在设计视图中固定好宽度后,浏览时就会变宽,这要怎么办?请各位大侠帮忙解决,不胜感激!
<asp:GridView ID="gvList" runat="server" AllowSorting="True" CellPadding="0" ForeColor="#333333" GridLines="None" Width="565">
<EditRowStyle BackColor="#999999" />
<RowStyle BackColor="#F7F6F3" ForeColor="#333333" />
<FooterStyle BackColor="#5D7B9D" Font-Bold="True" ForeColor="White" />
<PagerStyle BackColor="#284775" ForeColor="White" HorizontalAlign="Center" />
<SelectedRowStyle BackColor="#E2DED6" Font-Bold="True" ForeColor="#333333" />
<HeaderStyle BackColor="#5D7B9D" Font-Bold="True" ForeColor="White" />
<AlternatingRowStyle BackColor="White" ForeColor="#284775" />
</asp:GridView>
在浏览器中浏览时就自动加宽了 展开
<asp:GridView ID="gvList" runat="server" AllowSorting="True" CellPadding="0" ForeColor="#333333" GridLines="None" Width="565">
<EditRowStyle BackColor="#999999" />
<RowStyle BackColor="#F7F6F3" ForeColor="#333333" />
<FooterStyle BackColor="#5D7B9D" Font-Bold="True" ForeColor="White" />
<PagerStyle BackColor="#284775" ForeColor="White" HorizontalAlign="Center" />
<SelectedRowStyle BackColor="#E2DED6" Font-Bold="True" ForeColor="#333333" />
<HeaderStyle BackColor="#5D7B9D" Font-Bold="True" ForeColor="White" />
<AlternatingRowStyle BackColor="White" ForeColor="#284775" />
</asp:GridView>
在浏览器中浏览时就自动加宽了 展开
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询