Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
1541 Connection Busy and Remote Views
Message
From
30/12/1999 10:54:36
 
 
To
30/12/1999 10:31:21
General information
Forum:
Visual FoxPro
Category:
Other
Miscellaneous
Thread ID:
00310385
Message ID:
00310405
Views:
19
Chris, I suspect you have the view setup with buffering.

When you issue a APPEND BLANK to add a record to the view, the buffered fields will contain blanks. If you move off the record (without doing any REPLACE on all or some of the fields) or do some thing to push the new record to the backend database, the backend data will contain .null. in each of those fields, but your buffer still thinks those fields contain blanks. Now when you try to do a REPLACE on a field, foxpro starts getting confused by .null. / blank thing.

If you do a TABLEREVERT() right before your REPLACE, you probably wont get the error.

The correct thing to do is after an APPEND BLANK, do a REPLACE on each field in the table, whether or not you have data for each field right then. Even if you do a REPLACE xyz WITH "" the backend will not contain a .null. when the data is pushed back.

Another thing I try to do, is to not move the record pointer off the new record until the TABLEUPDATE() is fired (even though I am using table buffering). When the user is editing an existing record, I don't work to much about moving the record pointer.

If that does not solve your problem, you might be using table buffering and using TABLEUPDATE() instead of TABLEUPDATE(1). TABLEUPDATE() just updates the currently select row. TABLEUPDATE(1) makes sure any changed rows get updated on the backend.

Rob.
Previous
Reply
Map
View

Click here to load this message in the networking platform