I used databoundgrid with dataset as data source. After I query the database and load the data, it seems the grid will put DateTime type data in a DateTimePicker. And I can only see date(as 5/20/04). Is there any way for me to see the time only( or at least Date with time)?
I had a look on the samples and tried to define the col type as DateTime, but it did not work out.
Thanks a lot
ADAdministrator Syncfusion Team May 21, 2004 07:51 AM
By default, the GridDataBoundGrid places a MonthCalendar cell control if you column has datatype of DateTime. And, this control does not allow you to set the time.
But you can see the time by providing the proper GridBoundColumn.StyleInfo.Format property that includes the time. This sample shows this formatting and hides the button so the user cannot drop the calendar and kill the time.
If you want to use a DateImePicker in the cell (instead of the deafult MonthCalendar), here is a KB article that contains a custom cell type that does this.