|
-
Dec 1st, 2008, 11:28 AM
#1
Thread Starter
New Member
Specify Database Location of subreport
Hello,
I have a report with a sub-report but when specifying the location for the subreport it fails saying table doesn't exist. When I remove subreport it works fine. Both main and subreport use the same table, here the code...
Set Report = New CRProgMaqImp4
Report.Database.Tables(1).Location = "wcajtot" & RsUsu.Fields("Usuario")
Set crSubReport = Report.OpenSubreport("Tarimas")
crSubReport.Database.Tables(1).Location = "wcajtot" & RsUsu.Fields("Usuario")
Thanks.
-
Dec 1st, 2008, 01:00 PM
#2
Re: Specify Database Location of subreport
Try :
Code:
Set crSubReport = Report.OpenSubreport("Tarimas")
For K = 1 to crSubReport.Database.Tables.Count
crSubReport.Database.Tables(K).Location = "wcajtot" & RsUsu.Fields("Usuario")
Next K
-
Dec 1st, 2008, 01:17 PM
#3
Thread Starter
New Member
Re: Specify Database Location of subreport
Thanks jggtz, it didn't worked using this way, I solved problem using other way...
on the subreport i was using "INNER JOINS" between tables, what i did was added additional fields on the master table to prevent the use of JOINS, it worked fine with the same code.
Many thanks.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|