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
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Question on datagrid sorting for windows forms.

Thread ID:




1471 Nov 1,2002 12:36 PM UTC WinForms 0
Tags: FAQ
C C Hyman
Asked On November 1, 2002 12:36 PM UTC

I have a datagrid that is bound to a datatable. The datatable.defaultview can be sorted and filtered. The user has selected row #1 which has a column of caseid = "Case123". The user changes the sort of the grid from caseid to the column of closeddate. Row #1 is now caseid = "Case987" and caseid "Case123" is now row #10. The selected row is still row #1. I want to keep the selected row on "case123" (now row #10) after the sort change. I tried datatable.defaultview.find("Case123"), but this requires changing the sort back to the caseid. Any ideas on how to reset the selected row (currentrowindex) the original selected caseid of "Case123"?


This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Please sign in to access our forum

This page will automatically be redirected to the sign-in page in 10 seconds.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon

Live Chat Icon For mobile
Live Chat Icon