Home > DeveloperSection > Forums > I want to pass value from another datatable
Chintoo Semi

Total Post:135

Posted on    January-22-2014 11:19 PM

 C# C# 

 1 Reply(s)
 910  View(s)
Rate this:

I am having one datatable to that table i want to pass value from another datatable.

for example:-

datatable1 in this i want to pass value from datatable2.row[0]["colname"]

I tried like :-

tblvdr.Rows[0]["item_Vendorname"] = dttemp.Rows[0]["item_Vendorname"];

error message:-

its showing error for No row at o position

Pravesh Singh

Total Post:412

Posted on    January-23-2014 12:17 AM

Hi Chintoo,

try this:-

DataRow tblvdrRow = tblvdr.NewRow();

 tblvdrRow["item_Vendorname"]= dttemp.Rows[0]["item_Vendorname"];


Don't want to miss updates? Please click the below button!

Follow MindStick