VB Chap 8 p270 Try It Out
Hello.
I have read other threads on this topic but still had some trial and error to get it working. I need some help understanding why my "solution" finally got it working correctly.
My only problem occurred when I tried to complete and Update using the DetailsView control (the Edit mode itself worked just fine). I got the following error:
"You have specified that your update command compares all values on SqlDataSource 'SqlDataSource2', but the dictionary passed in for oldValues is empty. Pass in a valid dictionary for update or change your mode to OverwriteChanges."
Here is the WHERE clause in the UPDATE parameter of my datasource for the DetailsView. ...WHERE [FixtureID] = @original_FixtureID
I figured it couldn't hurt to try, so I changed the ConflictDetection parameter to "Overwrite Changes" and it worked fine. Go figure.
Can anyone explain how exactly that works, especially in conjunction with the DataKeyNames property because I got several errors about that while working through it all.
More importantly, can anyone some up what the steps in this exercise should have been? It was awfully confusing, and the errata suggestions didn't help at all.
Thanks in advance!
BKing
|