<asp:TemplateField HeaderText="日期">
<ItemTemplate>
<asp:TextBox ID="TxtDate" runat="server" Text='<%# fn_Rtn_DATE(Eval("Date")) %>'></asp:TextBox>
</ItemTemplate>
</asp:TemplateField>
Public Function fn_Rtn_DATE(ByVal dateDATE As Date) As String
If dateDATE > DateSerial(1900, 1, 1) Then
Return dateDATE.ToString("yyyy/MM/dd")
End If
Return ""
End Function
文章標籤
全站熱搜
留言列表