W
Wayne Wengert
I want to format a date field in a DataGrid column as mm/dd/yyyy. I am using
the following code:
<aspataGrid id="DataGrid1" AutoGenerateColumns="false"
EnableViewState="False" runat="server">
<columns>
<asp:BoundColumn DataField="RegionalID" />
<asp:BoundColumn DataField="StartDate"
DataFormatString="{d}" />
</columns>
</aspataGrid>
but I keep getting an error that it is not in the right format. Can anyone
point me to information about formatting a date in this instance. The book I
have shows the formatting for currency but not for dates and obviously I
didn't adapt it correctly.
Wayne
the following code:
<aspataGrid id="DataGrid1" AutoGenerateColumns="false"
EnableViewState="False" runat="server">
<columns>
<asp:BoundColumn DataField="RegionalID" />
<asp:BoundColumn DataField="StartDate"
DataFormatString="{d}" />
</columns>
</aspataGrid>
but I keep getting an error that it is not in the right format. Can anyone
point me to information about formatting a date in this instance. The book I
have shows the formatting for currency but not for dates and obviously I
didn't adapt it correctly.
Wayne