-
My report was OK the first time I run it from a menu. However when i closed the report and returned to the menu to rerun it one more time. Error message show up "The operation requested by the application is not allowed if the object is closed"
Private Sub MnuOne_Click()
'need to decide the app.path at run time
'Employee.mdb is in WinNt shared drive
DeConn.Conn1 = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" & App.Path & "\Employee.mdb"
DeConn.Conn1.Open
RptActions.Show
DeConn.Conn1.Close
End Sub
What is my mistake on the above coding.
Best wishes
CT
-
Thank you for your advise on this matter.
Basically i have a data environment setup to connect with my mdb. I have a data report generating information to the screen/printer.
What I am trying to do is to tell the connection to use the proper path because my users are using shared drive in winnt.
If i hard code this program such as "E:\ABC\Employee.mdb" using the connection properties, it will works for me.
Like wise with this hard coding method, I can call the report.show many times without hitting any error message.
regards
-
fair enough - o you know at which line the error message is thrown?