Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How to refresh screen w/ new val as other user updates f
Message
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Miscellaneous
Thread ID:
00728837
Message ID:
00728914
Views:
14
Hi,

>As another user updates the original table (myTable), I’d like have all users’ screen to refresh with the new updated value(s). What do I need to change to be able to do so? (example: if user A changes refno from 12 to 146, then I’d like user B to see 146 instead of 12 as user B’s screen refreshes – maybe as he goes to the next record & gets back to it).

there's no automatic way to do this, but you could do it this way: add a timestamp (lastupdate) column to your tables. Then you can write update triggers that store the current date/time in the column when a record was changed. To your application you can then add a timer that checks, if any of the displayed record's timestamp has been changed. If there were changes, you can requery your view or SQL PT command and refresh the display.

Or as an easy solution (if you're displaying single records), you can always load or the record from the database when the user skips through the data. But this will cause more network traffic, so I personally would prefer the first option.

HTH,
Armin

Armin Neudert
Regional Director (Stuttgart) of German FoxPro User Group dFPUG

MCP for Visual FoxPro

Expert/Editor of the VFP section in the German Codezone community portal
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform