newrow rowstate modified?

  • Thread starter Thread starter Pipo
  • Start date Start date
P

Pipo

Hi,

I read data from files.
Dim row As DataRow = Source.NewRow

row("ID") = strData(1)

row("data2") = strData(0)

row("data3") = strData(2)



row("Processed") = blnDeleted

Source.Rows.Add(row)

I know that the records exists in the database but I want them to be
updated.
The problem is that the rowstate now is added, this must become modified so
the updatecommand kicks in (for about ten of thousands of records!)

How can this be done?

tia
 
Hi Pipo,

Do
row.AcceptChanges
and then
row("data2") = row("data2") ... or use any other writeable column
 
Thanks Miha


Miha Markic said:
Hi Pipo,

Do
row.AcceptChanges
and then
row("data2") = row("data2") ... or use any other writeable column

--
Miha Markic [MVP C#]
RightHand .NET consulting & development www.rthand.com
Blog: http://cs.rthand.com/blogs/blog_with_righthand/

Pipo said:
Hi,

I read data from files.
Dim row As DataRow = Source.NewRow

row("ID") = strData(1)

row("data2") = strData(0)

row("data3") = strData(2)



row("Processed") = blnDeleted

Source.Rows.Add(row)

I know that the records exists in the database but I want them to be
updated.
The problem is that the rowstate now is added, this must become modified
so
the updatecommand kicks in (for about ten of thousands of records!)

How can this be done?

tia
 
Back
Top