Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations wOOdy-Soft on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Updating data - refresh in multi user database

Status
Not open for further replies.

Moss100

Technical User
Aug 10, 2004
586
GB
When i cahnge a record on one computer, it does not change on another straight away.

The information updates when I open and close another form, but with the same form onpen on two computers, if i change information on one computer it is not reflected staright away on another. I have tried using requert tied to the 'on timer' event, which works, but makes the screen flicker. I guess there is a slicker way of doing this. Any ideas, thanks Mark
 
Pehaps the Refresh method ?

Hope This Helps, PH.
Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884 or FAQ181-2886
 
That's fine, but it requires the other user to refresh their machine all the time. I thought of tying the refresh property onto the on timer event, but this causes the screen to flicker all the time.

*NB Refreshing the database on entering the data on one machine does NOT cause the screens to update on other machines. They will update if you close the form and reopen it - but otherwise they do not.
 
Go to:

Tools > Options > Advanced

and change the refresh interval to a lower value.

Ed Metcalfe.

Please do not feed the trolls.....
 
One note of caution - setting the value too low may create excessive network traffic. Pick an interval that is short enough to accomplish what you want, but no shorter.

Ed Metcalfe.

Please do not feed the trolls.....
 
Thanks, but setting the refresh interval, still does not update an open form on another machine... a tricky one this!
 
Strangely the refresh interval appears to apply to the machine, rather than the specific database. This doesn't make a lot of sense to me, as it makes it more difficult to have independent settings for individual databases. It also means the setting change needs to be made on each PC that the database will be used on - it will then solve your problem.

Presumably there is a way of setting this option in code on startup of the database so that you won't have to visit all machines and change the value individually. I'll see if I can work out how it's done.

Ed Metcalfe.

Please do not feed the trolls.....
 
You need to use Application.SetOption to change the refresh interval of your application during the database's startup routines.

On close of the database it would probably be wise to set the value back to the default to ensure it doesn't mess up any other databases the user is accessing.

Code:
'Set refresh interval to one second (probably too low for most purposes
Application.SetOption "Refresh Interval (sec)", 1

Code:
'Set refresh interval back to default sixty seconds on close of database
Application.SetOption "Refresh Interval (sec)", 60

Ed Metcalfe.

Please do not feed the trolls.....
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top