Datagrid AllowSorting property

  • Thread starter Thread starter Carl Tribble
  • Start date Start date
C

Carl Tribble

I want to prevent my user from clicking on a column header and sorting the
items in my datagrid. I have tried setting the AllowSorting property to
false both in the property pages and in code (in the Form.Load event) but
still, when program runs user can click column header and list re-sorts!!

Thanks,
-Carl
 
Hi,

If you add a tablestyle to your grid set the tablestyles
allowsorting to false.

http://msdn.microsoft.com/library/d...sdatagridtablestyleclassallowsortingtopic.asp

Ken
--------------------
I want to prevent my user from clicking on a column header and sorting the
items in my datagrid. I have tried setting the AllowSorting property to
false both in the property pages and in code (in the Form.Load event) but
still, when program runs user can click column header and list re-sorts!!

Thanks,
-Carl
 
Back
Top