Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
CDataBehavior Class and Saving
Message
General information
Forum:
Visual FoxPro
Category:
The Mere Mortals Framework
Title:
CDataBehavior Class and Saving
Miscellaneous
Thread ID:
00380452
Message ID:
00380452
Views:
54
Kevin,

I'm using the kMoverObj class, and of course using a table buffered view for the selected list. I have a couple of extended properties for the rows in the selected list. When I change an existing one.... the UpdateReorderedItemsItems method is called to try and save these records one at a time....

Consequently, the Save method is called with a parameter of .F. (to indicate we only want to save this record). However, in the CDataBehavior class, the Save method is called and there is a piece of code in there to check if the view is table buffered. If it is, it scans the table so that it can set the primary key state to "Edited". It then proceeds to call TABLEUPDATE with a parameter of .F.

That is where the problem occurs, the view was scanned.... record pointer was changed.... TABLEUPDATE is trying to update the wrong record.

I just added " AND tlAllRows" to the IF expression where it checks to see if the view is table buffered to relieve the problem. Just thought I would let you know.

Doug Stalter

"According to the proverb, the best things are the most difficult." -Plutarch
Next
Reply
Map
View

Click here to load this message in the networking platform