How to determine active sort order parameter of a DataGrid

H

Hrvoje Vrbanc

Hello all!

I would be grateful if someone could offer me some help with the following
problem:

I have a DataGrid control with sort enabled. Therefore it could be sorted in
several different ways. The same datagrid also have a Button Column with
Update button. After the update action for any particular item is completed,
my update method calls FillDataGrid(sort_parameter) function to refresh the
DataGrid content. But...how could my update method know what is the current
sort order (i.e. sort parameter) in order to pass it to FillDataGrid
function in order for my DataGrid to remain sorted the way before the update
action?

Thank you in advance.

Hrvoje Vrbanc
 
H

Hrvoje Vrbanc

I should have been thinking more before posting!
I don't know if this is the best way but I simply put sort parameter
(hardcoded in forst page load and e.SortExpression after further sorting) in
a session variable that I then pass to my FillDataGrid function from update
method.

Hrvoje
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,766
Messages
2,569,569
Members
45,042
Latest member
icassiem

Latest Threads

Top