JimB wrote:
>How do I close a module (using code) that I opened using the Docmd.OpenModule
>Method? There doesn't seem to be any corresponding close method. (Access
>2000). When I open the module, it flashes onto the screen and then stays
>open. Also, how to you keep from switching to the Visual Basic Window when
>this happens?
Use DoCmd.Close acModule, modulename
I don't think there's a way to prevent the focus from
shifting to the module when you open it.
But, this is a pretty unusual thing to do. You are not
performing design time operations at runtime are you? If
you are, you should seriously reconsider your plan and find
another way to accomplish what ever you're trying to do.
--
Marsh
MVP [MS Access]
|