I have uploaded a report and created a datasource in Reporting Services 2005. When I view the report through Report Manager, it runs successfully and displays correctly.
However, when I try to open this report in an ASP.net application which uses a ReportViewer control to view the report, it returns an exception:
Exception Details: Microsoft.Reporting.WebForms.ReportServerException: The data source 'ReportTesting' cannot be found. (rsDataSourceNotFound)
A warning is logged in Event Viewer on the ReportServer server:
**Process information:
Process ID: 3536
Process name: w3wp.exe
Account name: NT AUTHORITY\NETWORK SERVICE**
**Exception information:
Exception type: ReportServerException
Exception message: The data source 'ReportTesting' cannot be found. (rsDataSourceNotFound)**
I can't figure out why the report and datasource runs fine through ReportManager but won't when I run it via the RepotrViewer. There are other reports on the server (using different datasources) which are running fine.
Update: To confuse matters further - If I go untick 'Enable this data source' in ReportManager, the following is returned when I try to run the report in the ReportViewer control:
Exception Details: Microsoft.Reporting.WebForms.ReportServerException: The report server cannot process the report. A data source associated with the report has been disabled. (rsDataSourceDisabled)
If I retick the option to 'Enable this data source', it reverts to the original exception.