Answer
Mar 12, 2007 - 06:32 AM
I've been looking for info on this and in principle it is the property SortMode on a Column, that has to be Automatic.
But this doesn't work with custom business objects associated with the datagridview.
So I found out through this article: http://msdn.microsoft.com/library/def... that I have to create a SortedBindingList class that I use to associate to the BindingSource to the DataSource.
There is an example of a simple implementation of that here: http://forums.microsoft.com/MSDN/Show...
I used that and it works fine.
I'm wondering why this is not implemented in the framework, but well...
But this doesn't work with custom business objects associated with the datagridview.
So I found out through this article: http://msdn.microsoft.com/library/def... that I have to create a SortedBindingList class that I use to associate to the BindingSource to the DataSource.
There is an example of a simple implementation of that here: http://forums.microsoft.com/MSDN/Show...
I used that and it works fine.
I'm wondering why this is not implemented in the framework, but well...
Add New Comment