close a form upon opening another.

  • Thread starter Thread starter postman
  • Start date Start date
P

postman

How to automatically close a form upon opening another.

I have two forms, the first prepares data for the second form, and have the same table. The second form is opened from a control button on the first.
I would like the first form to be closed when that button is hit, if possible.

Thanks in advance.
 
In the button's Click event, after you've issued the DoCmd.OpenForm, put
DoCmd.Close acForm, Me.Name:


DoCmd.OpenForm "MyOtherForm"
DoCmd.Close acForm, Me.Name



--
Doug Steele, Microsoft Access MVP

(no e-mails, please!)



How to automatically close a form upon opening another.

I have two forms, the first prepares data for the second form, and have the
same table. The second form is opened from a control button on the first.
I would like the first form to be closed when that button is hit, if
possible.

Thanks in advance.
 
Back
Top