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

Raddatepicker date formate

1 Answer 58 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
j
Top achievements
Rank 1
j asked on 11 Feb 2011, 04:16 AM
Hi,

Is there anyway to format the datapicker's date format?

For Radgridview's columns type are datetime and when click that cell within those columns, the cell shows datepicker. However, after select date,  it shows m/d/yyyy hh:mm:ss. Can it be formated to m/d/yyyy?

below the code is we assign that column to the type of Datetime.

                    GridViewDataColumn dataColumn = (GridViewDataColumn)grid1.Columns[column];
                    dataColumn.DataType = typeof(System.DateTime);
                    dataColumn.DataFormatString = "{0:d}";


Thank you

1 Answer, 1 is accepted

Sort by
0
Maya
Telerik team
answered on 11 Feb 2011, 07:58 AM
Hi j,

I have tested your code and once the DataFormatString is set to "{0:d}", the value is displayed as mm/dd/yyyy. Based on the information you provided, I get the impression that this is the format you require. Is that correct or is there any misunderstandings according to your necessities ?
 

All the best,
Maya
the Telerik team
Let us know about your Windows Phone 7 application built with RadControls and we will help you promote it. Learn more>>
Tags
General Discussions
Asked by
j
Top achievements
Rank 1
Answers by
Maya
Telerik team
Share this question
or