Hi there,
I have a situation where I have a windows application that uses Microsoft Report Viewer Control. I am using the following code which is working fine on my development machine.
reportPath =
"ABS_Monthly_Expense_Recorder.REPORT.Report_By_Date.rptDate.rdlc";
// Set the active report path of the ReportViewer object
reportViewer1.LocalReport.ReportEmbeddedResource = reportPath;
// Add data source to the local report
// Note that the name should either be passed as parameter or
// parsed from the report document
reportViewer1.LocalReport.DataSources.Add(
new ReportDataSource("FinancleReport_MainTable", dsFinance.Tables["FinanceReport"]));
reportViewer1.RefreshReport();
I now took the debug folder on a different machine where they have only .Net framework installed. The exe is working fine, other forms are working perfectly. However, the form containing the report viewer control, though loads fine but giving an error while generating report. I have included the following two dlls in the same directory as the exe, as the form containing the report Viewer control wasn't loading without them:
1) Microsoft.ReportViewer.Common
2) Microsoft.ReportViewer.Winforms
I have also put all the rdlc reports that are required in tha same directory as the exe. Still, the error while loading report persist. Any advice? Thanks in advance and also for reading my problem.