Henk
  • Henk
  • Newbie Topic Starter
2011-01-25T06:41:36Z
Hi,
How can I sort a column by clicking its header containing dates?
Regards,
Henk
Igor/10Tec
2011-01-25T08:03:45Z
Henk, if you used the default column settings when you uploaded your date data in the native .NET format, the dates should be sorted properly. In most cases when our customers have problems with sorting, the reason is an improper cell value type. Check that the type of your data is the .NET DateTime type and you use the default sort type (iGSortType.ByValue) for your column.
2011-06-30T14:15:41Z
I'm also having this problem at the moment.

The data is being filled via MySQL and FillWithData(), and the SQL command we're using returns the Date directly in .NET "short" datetime format (for example, 30/06/2011). However, I just can't sort correctly on this column - it will return them in "groups", for example one batch of 2010 dates, then some 2007, then some 2009.

Could it possibly be that it needs to be in US format to work correctly? (ie, 2011-06-29) Mathematically this makes sense as sorting using the default ByValue type would return the right results, but it would never work in non-US formats if that were the case.

I'm confused 🙂
Igor/10Tec
2011-07-01T08:06:11Z
The problem is definitely in the type of your date values you sort. Check this type for the cell values IN THE GRID. Is it the std .NET DateTime structure?