General information
Category:
Forms & Form designer
Hi Nadia
I used to find this problem with VFP3, with an order processing form displaying order items in a grid. There were several relations set to readonly and read-write tables from the order headers table. The read-write tables were all table-buffered optimistically. This is the fix I used:
=RLOCK("orders") && Header, displayed on form
=RLOCK("odlines") && Items, displayed in grid
=RLOCK("stylcols") && stock table, not displayed but updated
=RLOCK("styles") && read-only, displayed in grid
=RLOCK("colours") && read-only, displayed in grid
UNLOCK ALL
Note that checking the lock status on any of the tables gives a negative result. And of course with optimistic locking, nothing should have been locked anyway. The RLOCK() is essential - just issuing UNLOCK doesn't work.
I usually place this code in a method on the grid called .bugfix() <s>, and call it after any child tables ("odlines" and "stylcols") are written to.
HTH
ChrisM, London, still winter.
Previous
Next
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only