I'm trying to pass a DataSet to a SubReport. I don't want the DataSet to be the SubReport's DataSource. The SubReport has a chart and table in it which will display the contents of the passed DataSet.
The only way I see to pass values to a SubReport is via ReportParameters. That, however, does not allow passing objects. Doing SubReport.ReportSource on DetailSection.ItemDataBound leaves the first detail section without a DataSet.
Is it possible to get to the actual report object (SubReport.ReportSource) per detail section?
The only way I see to pass values to a SubReport is via ReportParameters. That, however, does not allow passing objects. Doing SubReport.ReportSource on DetailSection.ItemDataBound leaves the first detail section without a DataSet.
private void detail_ItemDataBound(object sender, EventArgs e) |
{ |
Telerik.Reporting.Processing.DetailSection detailSection = (Telerik.Reporting.Processing.DetailSection)sender; |
DataRow row = (DataRow)detailSection.DataObject.RawData; |
TUsageSubReport subReport = (TUsageSubReport)this.UsageSubReport.ReportSource; |
DataSet ds = null; |
DB.Reports_GetAccountUsages(Convert.ToInt32(row["UserId"]), new DateTime(2009, 10, 1), new DateTime(2009, 10, 31), m_ConnectionString, out ds); |
subReport.Usages = ds; |
} |
Is it possible to get to the actual report object (SubReport.ReportSource) per detail section?