Opening report in another database

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I have the following code which opens a connection to another access
database. How can I modify or add to this code to print a specific report
from this database?

Private Sub Command0_Click()
Dim conn As New ADODB.Connection
Dim prop As Property
Dim strg As String

strg = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=D:\EUsers\reports\My
Documents\Access Reports\Balance Center.mdb;Persist Security Info=False"

conn.Open strg


I have several access databases which have linked data to another program
"Medisoft". My goal is to create a way to open each individual access
database and print a monthly report from a command button. Bottom line I do
not want to have to open each database and report manually.
 
Consider opening the other db using a command-line switch. You can call a
macro from the commandline. Create macros that open reports and then quit the
database. Open the db's by using the Shell command.

HTH,
Barry
 
Back
Top