there are a number of ways to handle this. the "best" solution will be determined by your architecture.
1. Do you use DataTables or POCOs to represent your data?
2. Are you passing the sort to a new page, or are you posting back to the same page (assuming webforms).
3. How long do you need to keep the sort is scope? between:
Postbacks
Form page 1 to page 2
For the life of current session
Persisted between sessions (login>logout, login again)
I would guess the simplest solution will be to keep the name of the column(string) and the direction(bool) of the sort. from there you can piece together a sort expression.
Jason Meckley
Programmer
Specialty Bakers, Inc.
faq855-7190