This is a migrated thread and some comments may be shown as answers.

Subreport - Business Objects

1 Answer 223 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Jeffrey
Top achievements
Rank 1
Jeffrey asked on 27 Jan 2008, 03:44 PM
1) I am trying telerik reporting as I need to create a 4 level sub report. I think it's possible in Telerik.
2) I am trying to create a report with just one sub report in it as of now. I have 2 reports- Master report and a sub report. But I need to feed the data programatically to both the reports(using Business Objects and not a SQL server query.) I don't see anything when I try to do that. If I create the sub report, using SQL query it runs fine. Can anyone please tell me how to set the data dynamically in a sub report.

Following is the snippet

Report1

report1 = new Report1();//Main Report

Report2Sub1 rep2Sub1 = new Report2Sub1();//Sub report

//Bind Collection 1 to Main report

report1.DataSource = list;


//Bind Collection 2 to Sub report 

rep2Sub1.DataSource = lpmd;

Telerik.Reporting.

SubReport subr = new Telerik.Reporting.SubReport();

subr.ReportSource = rep2Sub1;

subr.Visible =

true;

//I made this subreport1 property to public instead of private.
report1.subreport1 = subr;

Thanks in Advance,
-Jeff

1 Answer, 1 is accepted

Sort by
0
Milen | Product Manager @DX
Telerik team
answered on 28 Jan 2008, 02:09 PM
Hi Jeffrey,

Yes, you have chosen the right approach to display master-detail business objects using subreports.

Please review the example in the forum post object data binding in report.

Write us again if you have any further questions.

Sincerely yours,
Milen
the Telerik team

Instantly find answers to your questions at the new Telerik Support Center
Tags
General Discussions
Asked by
Jeffrey
Top achievements
Rank 1
Answers by
Milen | Product Manager @DX
Telerik team
Share this question
or