This is a migrated thread and some comments may be shown as answers.

Showing only Date (Not time) in a datetime column in a gridview.

4 Answers 1472 Views
GridView
This is a migrated thread and some comments may be shown as answers.
Johnny Funch
Top achievements
Rank 2
Johnny Funch asked on 02 Sep 2009, 02:22 PM
Hi,

How do I format a datetime column in a radgridview control?

I want to show ONLY the date part of the variable. 

I DID try removing it before entering it into the Grid, but then it just shows 12:00:00

I am guessing it has to do with DataEditFormatString or FormatString in the advanced settings for the column, but I've tried all kinds of strings with no luck.

Thanks
Johnny

4 Answers, 1 is accepted

Sort by
0
Johnny Funch
Top achievements
Rank 2
answered on 02 Sep 2009, 02:27 PM
Figured it out...

Just add {0:dd/MM/yy} to the FormatString property under Advanced Settings for the Column in the property builder.

tnx
~j
0
Nick
Telerik team
answered on 02 Sep 2009, 02:33 PM
Hello Johnny Funch,

Thank you for sharing that with the community.

Greetings,
Nick
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
0
Gauri
Top achievements
Rank 1
answered on 28 Sep 2012, 12:46 PM
Thanks
0
Aneta
Top achievements
Rank 1
answered on 10 Feb 2015, 10:04 AM
Hello,

what if i don't want to set custom format on every single grid? Is any Chance i can just set Format to Short and not have a time included (in entire application)?
Tags
GridView
Asked by
Johnny Funch
Top achievements
Rank 2
Answers by
Johnny Funch
Top achievements
Rank 2
Nick
Telerik team
Gauri
Top achievements
Rank 1
Aneta
Top achievements
Rank 1
Share this question
or