I have an application (connected to an access d/b) where users log a record. What I would like is to be able to generate an email if after 20 minutes the record is still open. I know how to generate the email but is it possible to have such a timer?
yes there is a way (assuming only one page is open)
use the timer funcion of javascript, set it to 20 minutes, open a popup window (if u do not want to disturb the current page displayed) and send the mail, close the popup window using javascript.
The problem i have is that this is a helpdesk type function so the a call is placed to the helpdesk, they then log the call in the database.
They may have several calls going at once so won't necessarily be sitting in any particular record so the suggested functionality would not suffice. I presume I need a process that sits in the background and performs regular checks?
I take it each record (or "call" has a status of open when you add it and then the status gets changed when a helpdesk member starts dealing with it? You want to notify someone when a call hasn't been dealt with within 20mins of being opened?
If this is correct, I would use some kind of scheduled job in the DB rather than an ASP page. eg, in SQL Server you could set up a job in SQL Agent that ran every 20mins, running a query similar to this:
Code:
SELECT * FROM table_name
WHERE status = 'open' AND opendate < DATEADD(n, -20, getdate())
Can you do anything with a Macro in Access? I'm assuming you've posted on the MS Access forum?
A not so pretty way would be to query the database for open recs when you are performing other operations. If the application is used quite frequently, but just have an individual who is sitting on a open record, then when other users perform an action, your operation will check open date/status field and send an email accordingly. Just a thought.
_______________________________
regards,
Brian
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.