Wrox Programmer Forums
Go Back   Wrox Programmer Forums > C# and C > C# 2005 > BOOK: Beginning C# 2005 Databases
|
BOOK: Beginning C# 2005 Databases
This is the forum to discuss the Wrox book Beginning C# 2005 Databases by Karli Watson; ISBN: 9780470044063
Welcome to the p2p.wrox.com Forums.

You are currently viewing the BOOK: Beginning C# 2005 Databases section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old November 12th, 2008, 04:45 PM
Friend of Wrox
 
Join Date: Oct 2004
Posts: 553
Thanks: 0
Thanked 1 Time in 1 Post
Send a message via MSN to vinod_yadav1919 Send a message via Yahoo to vinod_yadav1919
Default Is it possible to copy n-row to another dataset?

Is it possible to copy n-row to another dataset?

Currently I am using below code published in another forum..
dim srcRow, dstRow as DataRow, dstTab as Datatable
  srcRow=...
  dstRow=dstTab.NewRow()
  For i as integer=0 to dstrow.columns.count-1
    dstRow(i)=srcrow(i)
  Next
  dstTab.Rows.Add(dstRow)

is there any other way that will copy faster than this??

Any input or pointer will be great !!

Cheers :)

vinod
__________________
Cheers :)

vinod
 
Old November 12th, 2008, 08:53 PM
Friend of Wrox
 
Join Date: Jun 2008
Posts: 1,649
Thanks: 3
Thanked 141 Times in 140 Posts
Default

Well, if the two rows are *THAT* compatible, you probably don't need to copy the fields one by one.

You can probably just do
    dstTab.Rows.Add( srcrow )

Did you try that???





Similar Threads
Thread Thread Starter Forum Replies Last Post
How to copy n-row to another dataset? vinod_yadav1919 C# 0 November 12th, 2008 04:48 PM
Copy DataSet prasanta2expert ASP.NET 1.0 and 1.1 Professional 1 January 22nd, 2007 09:30 AM
copy entire row stealthdevil Access VBA 3 December 1st, 2006 11:39 AM
Copy dataset to another dataset kapila VB.NET 2 November 13th, 2005 06:25 AM
copy datacolumn from one dataset to another hkpanda ADO.NET 1 July 25th, 2003 12:04 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.