We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date
close icon

Format a date in a bound datagrid

How do I format a date in a bound datagrid? I've tried changing the styleinfo of a boundcolumn but it keeps giving me the basic format. By the way, it is bound to a typed dataset. I want to see the date and time.

4 Replies

AD Administrator Syncfusion Team November 26, 2002 08:30 PM UTC

Setting the StyleInfo.Format in the GridBoundColumn is the proper way to do this, but there is a bug in version 1.5 that prevents this format from 'taking'. This problem will be corrected in a 1.5.1 patch release in the next day or so.


SB Soung Bae December 4, 2002 06:02 PM UTC

I just wanted to ask you if this issue was fixed with the new patch? > How do I format a date in a bound datagrid? > > I've tried changing the styleinfo of a boundcolumn but it keeps giving me the basic format. > > By the way, it is bound to a typed dataset. > > I want to see the date and time.


AD Administrator Syncfusion Team December 4, 2002 06:42 PM UTC

Yes. Stefan


SB Soung Bae December 4, 2002 06:58 PM UTC

> Yes. > > Stefan Thanks. I figured out a way to do this without a typed dataset using grdResults.Binder.InternalColumns[1].StyleInfo.CellValueType = typeof(DateTime); grdResults.Binder.InternalColumns[1].StyleInfo.Format = "ddMMMyyyy";

Loader.
Live Chat Icon For mobile
Up arrow icon