@Christopher Nigro
Actually this is what I am doing. this is only a chunk of my main code. "attrib_num" contains the column number where i want to insert new value in the table and "marked_attribute_dec" is the new value which i want to add in the specified column number replacing the old value.
but the code below adds new rows with the new values in the table. i want the same rows with the new values in them. In other words i want to replace some of the values of the original table rows with new column values. I dont want to have additional rows with new values. i just want to alter values in the existing rows.
please give me some suggestions. I really need assistance
[code.......
DataRow row1 = ds.Tables["Table1"].NewRow();
for (int p = 0; p <column_count; p++)
{
if (p == attrib_num)
row1[p]=marked_attribute_dec;
else
row1[p] = attributes[p];
}
ds.Tables["Table1"].Rows.Add(row1);
conn.Close();
DataTable dt = ds.Tables["Table1"];
adapterx.Update(dt);
conn.Close();
...............................code]
thanku