Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

CHANGE CR9 SUBREPORT DB AT RUNTIME

Status
Not open for further replies.

kissarmi

Programmer
Feb 14, 2002
72
US
I am changing the database for my CR9 report at runtime using a Visual Basic application and this code:

For x = 1 To REPORTNAME.Database.Tables.Count
With REPORTNAME.Database.Tables(x).ConnectionProperties

.Item("Database") = "DATABASENAME"
.Item("Server") = "SERVERNAME"
.Item("User ID") = "USERID"
.Item("Password") = "PASSWORD"

End With

REPORTNAME.Database.Tables.Item(x).Location = REPORTNAME.Database.Tables.Item(x).Location

The database change is working for the main report, but I need some help in changing the database for the subreports. How do I loop thru the subreports in order to change their database?

Thanks.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top