Talk About Network

Google


Register and Login
Nick
Password
Register create new account Sign up is FREE and you can post replies, new topics, bookmark posts and more!
Recover lost password


Software > ADO Data > How to catch a ...
Latest [ Topics | Posts ] Archive Post A New Topic Post a Reply
<< Topic < Post Post 1 of 2 Topic 4202 of 4320
Post > Topic >>

How to catch a zero net change in a DataSet before Adapter Update?

by "Jason" <jason@[EMAIL PROTECTED] > Apr 8, 2008 at 10:39 PM

I'm relativley new to using DataSets with Adapters but I think I've gotten 
most of what I need working. However, I've tripped over a special case.
That 
scenario is where I add a row to my DataSet but then I wind up marking
that 
row for deletion before I get to the Update. I keep getting a 
System.InvalidOperationException and I'm not sure why. My DeleteCommand's 
parameters use the OriginalVersion of the row to find and delete rows. But

any newly added rows marked for delete shouldn't have an Original version.

This maybe the problem. I thought I could just use a foreach loop on the 
Rows and everything I found a row that was marked for delete but had no 
original version I could simply remove it but that too seems to cause an 
exception. Is there a correct way to handle this scenario?

Thanks,

Jason
 




 2 Posts in Topic:
How to catch a zero net change in a DataSet before Adapter Updat
"Jason" <jas  2008-04-08 22:39:15 
Re: How to catch a zero net change in a DataSet before Adapter U
"Bob Barrows [MVP]&q  2008-04-09 06:12:19 

Post A Reply:
  Go here to Signup

AddThis Feed Button


About - Advertising - Contact - Frequently Asked Questions - Privacy Policy - Terms of Use - Signup

Contact
tan12V112 Sat Nov 22 15:53:23 CST 2008.