I know that docmd.close will close the current form but for some reason I have gotten it in my head that I want to be more explicit. What I do is docmd.close acForm, me.name.
Is that totally crazy or is there a good reason to do this?
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Calling DoCmd.Close with no argument closes the active window. Using the Me.Name syntax accounts for scenarios where the form in question is not the active window (example running hidden). Personally I prefer the explicit version as it does exactly what you want, whereas the implicit version will probably do what you want.