Re: Networking Problem with Delphi
Posted by webmaster Guido on October 05, 2003 at 17:34:18:
In Reply to: Networking Problem with Delphi posted by Mark on September 28, 2003 at 12:22:47:
: Dear Forum Members,
: I'm experiencing problems with networking two workstations running Delphi, whereby I intend to share a database table between these two workstations.
: However, when I apply changes to the **.DB file on the first workstation, the changes are not reflected on the datagrid of the second workstation.
: I understand that it could be because the database table is locked but I need help from the Forum on how to resolve the unlocking of this database table for simultaneous database updates to a single table from two separate workstations networked through a router.
The datagrid on the second workstation only shows the updated data when you "refresh" the database table:
- for a TTable: use Table1.Refresh;
Of course, the problem lies in not knowing when one of the other workstations changed the database table... So your app should refresh the grid, if that grid is showing info for longer than N seconds:
A. Use a TTimer for automatically refreshing every N*1000 milliseconds).
[ DelphiLand: free Delphi source code, tips, tutorials ]