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 strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Create a subform using CreateReportControl

Status
Not open for further replies.

MrMajik

IS-IT--Management
Apr 2, 2002
267
I need to create a subform using CreateReportControl

I have the code working that creates a report on the fly using CreateReportControl but now I realize I need to access two tables to populate the report. Does anyone have experience doing this?

Thank you.
 
Clarification: My first post says, "I need to create a subform using CreateReportControl"

It sould read, "I need to create a subreport using CreateReportControl"

I apoligize for any confusion this may have caused.

MrMajik
 
I found the solution and for the record here it is:
I created a report and subreport using the report wizard. Then I veiwed the Properties of the newly created report and went to Data | Record Source and copied the SQL string to the

myReport.RecordSource = &quot;<insert copied sql string here>&quot;

line of VB code. It works just as slick as you will :)

MrMajik
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top