views:

33

answers:

1

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?

+2  A: 

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.

Oorang
That is exactly what I was looking for, I knew there had to be a reason I was typing it out explicitly. thanks.
Icode4food