Clone datatable rows

  • Thread starter Julián Sanz García
  • Start date
J

Julián Sanz García

Hi,

I want to copy datatable rows in other datatable without using loops. Clone
method in datatable object copy table structure but not data and there is no
clone method in datarow object.
The only way i have found is import each row of the old datatable, in new
datatable. But i don't like this way very much because i think it isn't so
much optimal
Can anybody help me?

thanks a lot
 
C

caiokf

Hi,

I want to copy datatable rows in other datatable without using loops. Clone
method in datatable object copy table structure but not data and there is no
clone method in datarow object.
The only way i have found is import each row of the old datatable, in new
datatable. But i don't like this way very much because i think it isn't so
much optimal
Can anybody help me?

thanks a lot

Instead of the Clon method, use the Copy method, that copies both
structure and data from a datatable to another
 

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