日期:2014-05-19  浏览次数:20390 次

datagrid 中 findcontrol 只有十分了
<asp:DataGrid   Runat= "server "   ID= "RepliesGrid "   AllowCustomPaging= "True "   AutoGenerateColumns= "False "   CssClass= "Forums_General "   HeaderStyle-CssClass= "Forums_Header "   DataKeyField= "ReplyID "   OnUpdateCommand= "RepliesGrid_Update "   OnCancelCommand= "RepliesGrid_Cancel "   OnDeleteCommand= "RepliesGrid_Delete "   ShowHeader= "False "   Width= "100% ">
<Columns>
<asp:TemplateColumn   ItemStyle-BorderColor=lightblue   ItemStyle-BorderStyle=Solid   ItemStyle-BorderWidth=4   ItemStyle-Width= "160px "   ItemStyle-HorizontalAlign= "Center ">
<ItemTemplate>
<br>
<b>
<%#   GetAuthorText(
DataBinder.Eval(Container.DataItem,   "employeeName "),
DataBinder.Eval(Container.DataItem,   "mail_address ")
)   %>
</b>
<br>
<asp:Image   Runat= "server "   ImageUrl= ' <%#   DataBinder.Eval(Container.DataItem,   "AvatarUrl ")   %> '   Visible= ' <%#   DataBinder.Eval(Container.DataItem,   "AvatarUrl ").ToString().Length> 0   %> '   />
<br>
<small>
<%#   DataBinder.Eval(Container.DataItem,   "belong2Name ")   %>
-
<%# DataBinder.Eval(Container.DataItem,   "positionName ")   %>
                                </small>
                                <br>
<small> Post   date:
<br>
<%#   DataBinder.Eval(Container.DataItem,   "AddedDate ",   "{0:MM/dd/yyyy} ")   %>
-
<%#   DataBinder.Eval(Container.DataItem,   "AddedDate ",   "{0:HH:mm:ss   tt} ")   %>
</small>
</ItemTemplate>
</asp:TemplateColumn>
<asp:TemplateColumn   ItemStyle-BorderStyle=Solid   ItemStyle-BorderColor=lightblue   ItemStyle-BorderWidth=3>
<ItemTemplate>
<table   runat=server   width= "100% "   height= "160px "   cellpadding= "1 "   cellspacing= "1 "   rules= "none " border=2   style= "word-break:break-all ">
<tr>
<td   valign= "top ">
<%#   ProcessTags(DataBinder.Eval(Container.DataItem,   "Message "))   %>
<br>

<br>
<br>
</td>
</tr>
<tr   height= "20 "> <td   align=right>
<asp:Label   id= "ReplyState "   runat= "server "   ForeColor= "#C00000 "> <%#   DataBinder.Eval(Container.DataItem,   "FileState ")   %> </asp:Lab