closing a form

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I have multiple forms that I close with a command button with the code

DoCmd.Close acForm, "name of form"

It works for all my forms except one. These forms are just for data entry,
there are no subforms.

Thanks
 
Check the OnUnload Property of the form, mybe it has in the code cancel=true,
that wont let the form close in some conditions
 
You may wish to also try DoCmd.Close acForm,Me.Name

The name property is the name of the current form --- this save headaches if
you rename the form someday....
 
DoCmd.Close acForm, Me.Name worked, thanks guys!

Bob Howard said:
You may wish to also try DoCmd.Close acForm,Me.Name

The name property is the name of the current form --- this save headaches if
you rename the form someday....
 
Back
Top