Using MS Access/Open and closing forms


Hi Scott
Back again.
I am using access 2010. I have a database with a main menu (unbound form), with the option to open forms and reports or close the database.
When I open a form from the main menu, the selected form (or report) opens on top of the Main Menu Form.
I find this untidy, and confusing for the other users of the database.
How do I close the Main Menu form when I open the other form so that the newly opened form is the only one on the screen?
I would appreciate your help.

I thought I had answered this.

DoCmd.Close acForm, "formname", acSaveNo

Or you could just hide it:

Me.Visible = False

Use either immediately after you open the new form.

Then, in the On Close event of the calling form you need to reopen the menu or set Visible to True. In that case, use:

Forms!formname.Visible = True

Use that before you close the current form.

Hope this helps,
Microsoft Access MVP 2007
Author: Microsoft Office Access 2007 VBA

Using MS Access

All Answers

Answers by Expert:

Ask Experts




I can answer almost all types of questions relating to Microsoft Access usage and application design. My strengths are database and interface design.


I've been designing databases for over 25 years working with dBase, FoxPro, Approach and Access.

Author of Microsoft Office Access 2007 VBA
Techncial Editor for Special Edition Using Microsoft Access 2007 and Access 2007 Forms, Reports & Queries From Que Publishing

Brooklyn College BA

©2017 All rights reserved.