datatable-sort

R

reiks

I have a datatable . My requirement is to sort the table
rows in ascending and descending order basing on the
columns which I give it.

I've used the following expression

ds.Tables[0].DefaultView.Sort="au_fname";

but it's sorting in ascending order but not in descending.

How to specify the descending order.

also let me know how can I include multiple columns in my
above expression
 
M

Miha Markic

Hi,

Sure - both.
Just put in as many columns+sorting order you want.
Example

....Sort = "Column1 ASC, Column2 DESC, ...";
 

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

Top