Solved

Access 2003 timeout?

Posted on 2011-03-09
5
354 Views
Last Modified: 2012-05-11
I have an Access 2003 application that is used by out about 15 people that are often accessing the database simulataneously.  I am getting complaints that one user is losing information that she is entering into a query datasheet.  However this is consistent.  Sometimes she re-opens and some of the data was not saved, and other times it is saved.  The problem is hard to re-create but I was able to determine through questioning more that she does tend to leave Access open for long periods of time when she is not at her desk, so I think that it has to do with this.  During periods of her inactivity, the query has been left open, but other users have accessed the same tables that the query references and somehow their changes override what she has entered.  But I'm just not sure how Access handles this type of scenario.  Does anyone have thoughts of how to address this?  Some type of auto-timeout for the application that would close it out after some period of time?  I have tried telling her she needs to get in, make her changes, and get out, but this is not happening so I need a fix from the software side.  Thanks!
0
Comment
Question by:janderscu
  • 2
  • 2
5 Comments
 
LVL 77

Expert Comment

by:peter57r
ID: 35084264
Frankly , I don't see that there is a good solution.

How can software possibly know whether the user needs to save the record or not?

You can build a ' period of inactivity' test into the application that closes the app after a certain time, or you could use a timer event in the form to close after a certain time,  but it would be entirely a matter of chance in deciding whether you should be saving any unsaved data at that point.  And what if some validation rule fails if you attempt to save?


0
 
LVL 74

Expert Comment

by:Jeffrey Coachman
ID: 35084353
I'm with Pete.

As the developer, you can twist yourself into knots creating systems that attempt to protect users from themselves...
;-)

The key here is user education...

You may also wish to use forms for data entry, (not the "Query Datasheet"), so you have more control over users.

Finally, you can investigate all the different "Record Locking" strategies and settings in MS Access, but this is another topic.
;-)

JeffCoachman
0
 

Author Comment

by:janderscu
ID: 35084725
"You can build a ' period of inactivity' test into the application that closes the app after a certain time, or you could use a timer event in the form to close after a certain time"

How would you accomplish 'pediod of inactivity' test to close the app?  I think I will look closer at this.

Also, I am planning to convert the entry to a form and set the query as the source so I agree with you Jeff that would offer more control.  Assuming I did this , would the timer on the form make more sense than a totall close of the entire application?
0
 
LVL 77

Accepted Solution

by:
peter57r earned 250 total points
ID: 35085023
I hadn't realised you were NOT talking about forms (I know you said query datasheet, but i still assumed that it was a form).

To do anything at all you have to be using a form.

If it is one form that is the issue , then it is simpler to use the form timer event to control the process.

In the form_current event procedure do..

Me.timerinterval = 600000

This will set the trigger to10 minutes - adjust it necessary.

In the Form_Timer event procedure..

docmd.close acform, me.name

 (This will close the form and in doing so, attempt to save any changes.

0
 

Author Closing Comment

by:janderscu
ID: 35099085
The time out on the form I think is a good solution at this point and I will try this for a while to see if it is a reasonable work around.  Thanks
0

Featured Post

Complete VMware vSphere® ESX(i) & Hyper-V Backup

Capture your entire system, including the host, with patented disk imaging integrated with VMware VADP / Microsoft VSS and RCT. RTOs is as low as 15 seconds with Acronis Active Restore™. You can enjoy unlimited P2V/V2V migrations from any source (even from a different hypervisor)

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article is a continuation or rather an extension from Cascading Combos (http://www.experts-exchange.com/A_5949.html) and builds on examples developed in detail there. It should be understandable alone, but I recommend reading the previous artic…
Preparing an email is something we should all take special care with – especially when the email is for somebody you may not know very well. The pressures of everyday working life stacked with a hectic office environment can make this a real challen…
In Microsoft Access, learn how to “cascade” or have the displayed data of one combo control depend upon what’s entered in another. Base the dependent combo on a query for its row source: Add a reference to the first combo on the form as criteria i…
In Microsoft Access, when working with VBA, learn some techniques for writing readable and easily maintained code.

809 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question