you can use the forms onTimer event for this. Basically you would set the
Timer Interval on the form to the specified length of milliseconds and then
in the forms On Timer event enter code to shut down the database. Something
like this should work.
Private Sub Form_Timer()
On Error GoTo Form_Timer_Error
' Close the database
DoCmd.Quit
On Error GoTo 0
Exit Sub
Form_Timer_Error:
MsgBox "Error " & Err.Number & " (" & Err.Description & ") in procedure
Form_Timer of VBA Document Form_frm:2000RulesTableFilter"
End Sub
Please keeep in mind that this will shut down the database and any changes
that are not saved woll be when the database is shut down.
--
James B Gaylord
From the Wolf Comes the Strength of the Pack
From the Pack Comes the Strength of the Wolf
- R Kipling
--
James B Gaylord
From the Wolf Comes the Strength of the Pack
From the Pack Comes the Strength of the Wolf
- R Kipling
Message posted via AccessMonster.com
Ask a Question
Want to reply to this thread or ask your own question?
You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.