foreach (DataRow row in dtSource.Rows) { if (row.ItemArray[17].ToString().Length > 32) { string ss= "text"; row.ItemArray[17] = ss; // here it is not added in itemarray } } }
row.ItemArray
foreach (DataRow row in dtSource.Rows) { if (row[17].ToString().Length > 32) { string ss= "text"; row[17] = ss; } }
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)