Harish Chandra  Patel

Harish Chandra Patel

  • 1.6k
  • 76
  • 12.8k

Data retrieval failed for the subreport in RDLC Reporting

Sep 14 2016 8:44 AM
Hi All,
I have created nested reports using RDLC with sub report.
On local machine its working fine. but when I uploaded it on test server it showing error for child report. Error message is - 
Data retrieval failed for the subreport, 'SubReportName', located at: xxx.yyy.SubReportName.rdlc. Please check the log files for more information.
The code for sub report -
void SubReportQuestionHeadProcessing(object sender, SubreportProcessingEventArgs e)
{
switch (e.ReportPath)
{
case "SubRptQuestionHeads":
{
DataTable ldtQA = new DataTable();
int MonitoringDataID = Convert.ToInt32(e.Parameters["MonitoringDataID"].Values[0]);
int OrganizationId = Convert.ToInt32(e.Parameters["OrganizationId"].Values[0]);
int TemplateId = Convert.ToInt32(e.Parameters["TemplateId"].Values[0]);
int HeadID = Convert.ToInt32(e.Parameters["HeadID"].Values[0]);
String RowNumber = Convert.ToString(e.Parameters["RowNumber"].Values[0]);
ldtQA = Anidan.BLL.MonitoringData.GetMonitoringReportDataQuestionAnswersForMAStudy(MonitoringDataID, OrganizationId, TemplateId, HeadID, RowNumber);
e.DataSources.Add(new ReportDataSource("DS_QuestionAnswers", ldtQA));
break;
}
}
}
 
 
Please suggest the solutions if any one have.
Thanks in advance..
Harish Chandra Patel

Answers (1)