Hi, I am creating a DataTable on the fly(basically converting html table to datatable). I need a way to assign unique ID's to each cell in DataRow. I dont see datacell object to which I can assign Id's. what is the way to do it?
Thnaks!!
Code:
//create rows
foreach (TableRow SourceTableRow in sourceTable.Rows)
{
DataRow OutputTableRow = outputTable.NewRow();
//get data from cells
for (int i = 0; i <= SourceTableRow.Cells.Count; i++)
{
OutputTableRow[i] = SourceTableRow.Cells[i].Text;
OutputTableRow[i].ID = SourceTableRow.Cells[i].ID; //OutputTableRow[i] does not have ID property!
}
//add row to table
outputTable.Rows.Add(OutputTableRow);
}
Thnaks!!