DataTable existingDataTable = GetMeDataFromSomeWhere();
//Add a new row to table
DataRow newRow = existingDataTable.NewRow();
newRow["ID"] = 999;
newRow["SomeColumn"] = "Manas Bhardwaj";
existingDataTable.Rows.Add(newRow);
//OR If nedd row add in a specific row
existingDataTable.Rows.InsertAt(dr, 0);
//Add a new row to table
DataRow newRow = existingDataTable.NewRow();
newRow["ID"] = 999;
newRow["SomeColumn"] = "Manas Bhardwaj";
existingDataTable.Rows.Add(newRow);
//OR If nedd row add in a specific row
existingDataTable.Rows.InsertAt(dr, 0);
No comments:
Post a Comment