<GridColumn Field=@nameof(Order.OrderDate) CustomFormat="@(new { type= "date", format= "dd/MM/yyyy" })" Type="ColumnType.Date" ...></GridColumn>
|
Format |
Formatted value |
{ type=”date”, format=”dd/MM/yyyy”} |
04/07/1996 |
{ type=”date”, format=”dd.MM.yyyy” } |
04.07.1996 |
{ type=”date”, skeleton=”short” } |
7/4/96 |
{ type=”dateTime”, format= ”dd/MM/yyyy hh:mm a” } |
04/07/1996 12:00 AM |
{ type= “dateTime”, format= “MM/dd/yyyy hh:mm:ss a” } |
07/04/1996 12:00:00 AM |
<GridColumn Field="Date" HeaderText="Date" Width="80">
<Template>
@{
WeatherForecast Value = (context as WeatherForecast);
<span>@Value.Date.ToString("dd/MM/yyyy")</span>
}
</Template>
</GridColumn>
|