2010-12-15 8 views
0

GridViewのFooterTemplateにある要素の配置に問題があります。 誰もがit.Theコードを実行する方法を私に勧めている:フッター要素を左揃えにする方法

<asp:GridView ID="gvComment" runat="server" AutoGenerateColumns="false" 
OnRowDataBound="gvComment_RowDataBound" OnRowCreated="gvComment_RowCreated" Width="100%" ShowHeader="false" BorderWidth="0px" ShowFooter="true"> 
<Columns> 
<asp:TemplateField> 
    <ItemTemplate> 
    <table border="0" cellpadding="0" cellspacing="0" width="100%" > 
    <tr> 
    <td valign="middle" align="left" style="width:10%"><img id="imgUser" src="" alt="" title="" runat="server" /></td> 
    <td align="left" valign="top"> 
     comment comment 
     <asp:Label ID="lblNameComments" runat="server" Visible="false" ></asp:Label> 
    </td> 
    </tr> 
    <tr><td colspan="2" style="height:7px;"></td></tr> 
    <tr> 
    <td colspan="2" style="padding-top:10px;background-image:url(../Images/dotted_line.jpg);background-repeat:repeat-x;background-position:center;"></td> 
    </tr> 
    <tr><td colspan="2" style="height:7px;"></td></tr> 
    </table>    
    </ItemTemplate> 
</asp:TemplateField> 
<asp:TemplateField> 
    <FooterTemplate > 
    <table border="0" cellpadding="0" cellspacing="0" width="100%" > 
    <tr> 
    <td align="left"> 
    Footer Text 
     Footer Text 
     Footer Text   
    </td> 
    </tr> 
    </table> 
    </FooterTemplate> 
</asp:TemplateField> 
</Columns> 
</asp:GridView> 

私は左TDのプロパティを揃える設定しているが、それはwork.Page出力は画像に示されていません。

alt text

答えて

関連する問題