joedoer
May 14th, 2000, 07:48 PM
My vb pgm runs multiple queries and a report from within an
Access mdb but I can't get the vb pgm to close automatically when it's done. I have to click the close (X) button on the form to end it.
Any ideas?
On Error GoTo error1
'Center form on screen
Left = (Screen.Width - Width) \ 2
Top = (Screen.Height - Height) \ 2
Set msacs = New Access.Application
msacs.OpenCurrentDatabase "F:\User Files\holly\Access\Expediting.mdb"
msacs.Visible = False
msacs.DoCmd.RunMacro "RunReport"
msacs.CloseCurrentDatabase
Unload Me
error1:
Access mdb but I can't get the vb pgm to close automatically when it's done. I have to click the close (X) button on the form to end it.
Any ideas?
On Error GoTo error1
'Center form on screen
Left = (Screen.Width - Width) \ 2
Top = (Screen.Height - Height) \ 2
Set msacs = New Access.Application
msacs.OpenCurrentDatabase "F:\User Files\holly\Access\Expediting.mdb"
msacs.Visible = False
msacs.DoCmd.RunMacro "RunReport"
msacs.CloseCurrentDatabase
Unload Me
error1: