I'm using Datagridview control with 2 Checkbox column, one button column and few text columns. Datagrid text columns are populated from database table. I'm setting Checkbox column as 'selected' during Form_Load event. But when I press on column header of any of the Datagrid columns for sorting, it wipes out my setting of checkbox columns and gives unselected checkbox.
Is there any event that i can use on column header click where i can set values that i'm setting in Form_Load event?
FYI, I tried datagridview.ColumnHeaderClick event and it doesn't work. Any suggestion?