One option is to open your forms in modal modal so user have to close the
form themselves before being able to go elsewhere.
Another option would be to use the form's got focus event to close all open
forms. Something like:
Dim DbF As Form
Dim DbO As Object
Set DbO = Application.Forms 'Collection of all the open forms
For Each DbF In DbO 'Loop all the forms
If DbF.Name <> "SwitchboardFormName" Then
DoCmd.Close acForm, DbF.Name
End If
Next DbF
Set DbO = Nothing
--
Hope this helps,
Daniel Pineault
http://www.cardaconsultants.com/
For Access Tips and Examples:
http://www.devhut.net
Please rate this post using the vote buttons if it was helpful.
"CEL504" wrote:
> Help please! How do I get a form to close on exit. I have used a switchbord
> form where I navigate to other forms in the data base, what is the best way
> to close a form automatically I have finished reviewing it and I return back
> to the switchboard again?
>
> I have read some of the threads but still unsure where the code is written to.
>
>
> Cel504, many thanks>