所有子报表都作为空白报表添加到此Crystal报表中。
问题是数据不在子报表中显示,而仅在主报表中显示
rdreport.Load("C:/INTRANET/Project_Rollout_Management.rpt");
rdreport.Database.Tables[0].SetDataSource(ds1.Tables["Project_rollout_Management"]);
//rdreport.Load("C:/inetpub/wwwroot/INTRANET/Service_LOI_Agreement.rpt");
//rdreport.OpenSubreport("C:/inetpub/wwwroot/INTRANET/Service_LOI_Agreement.rpt").SetDataSource(ds_LOI);
if (ds1.Tables[0].Rows.Count > 0)
{
rdreport.SetDataSource(ds1.Tables[0]);// Main report
rdreport.Subreports[0].SetDataSource(ds_LOI.Tables[0]); // Subreport
rdreport.Subreports[1].SetDataSource(ds_PnL.Tables[0]);
rptReport_ProjectRolloutMngnt.ReportSource = rdreport;