Related Posts Plugin for WordPress, Blogger...

About

Follow Us

Wednesday, 4 February 2015

Introduction
In this article we will learn how to copy one DataTable to other in asp.net. Suppose we have a DataTable dt having some data and we want to copy this DataTable dt to other DataTable dtNew , then we have to write some following code:

C#.Net code to Copy one datatable data to other datatable in asp.net
DataTable dt = new DataTable();
DataTable dtNew = new DataTable();
dtNew = dt.Copy();

VB.Net code to Copy one datatable data to other datatable in asp.net

 Dim dt As New DataTable()
Dim dtNew As New DataTable()

dtNew = dt.Copy()
Categories: , ,

0 comments:

Post a Comment