help with datasets

G

Guest

hey all,

i have set the .DefaultView of my dataset.
how can i create a duplicate of the dataset with only the records in
..DefaultView?

thanks,
rodchar
 
O

Onin Tayson

Hi rodchar,

You can use the DataTable's Select method. i.e.

DataSet newDs = new DataSet();
newDs.Merge(origDs.Tables[0].Select("filterExpression", "sort"));

HTH,
 
G

Guest

HTH,
You bet it does. Thank you very much.

Onin Tayson said:
Hi rodchar,

You can use the DataTable's Select method. i.e.

DataSet newDs = new DataSet();
newDs.Merge(origDs.Tables[0].Select("filterExpression", "sort"));

HTH,


rodchar said:
hey all,

i have set the .DefaultView of my dataset.
how can i create a duplicate of the dataset with only the records in
.DefaultView?

thanks,
rodchar
 

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

Forum statistics

Threads
473,744
Messages
2,569,482
Members
44,900
Latest member
Nell636132

Latest Threads

Top