Overview
The Report Viewer control allows web application developers to leverage full-featured reports and present them to the user in an easy to use and intuitive interface. The Report Viewer 2008 ships as a part of Visual Studio, along with the integrated Report Designer. Reports can contain tabular, aggregated and multi-dimensional data. The ReportViewer Control also comes in a WindowsForm version for building report-enabled custom applications.
The ReportViewer allows the consume two types of reports, after some configuration via the web.config file:
- Local Reports: These are reports that are processed by the client application, via the ReportViewer control. Visual Studio 2008 contains a "Report Project" template to allow easy creation of these types of reports. Local Reporting is geared towards custom web applications.
- Remote Reports: These are reports tht are hosted via the Microsoft SQL Server Reporting Services report server. The ReportViewer control is used as a display mechanism to a report already defined and published in the Report Server. All processing of the data is rendered on the report server itself. Remote Reporting is geared towards larger scope applications in an enterprise environment.
The ReportViewer is one of the most overlooked and underdocumented tools in the Visual Studio arsenal. One of the primary issues with using the ReportViewer in a web environment is due to nebulous error messages, making it very difficult to pinpoint where the problem may be. Through this article, I intend to address "gotchas" that I've run into as I've developed hundreds of reports for a large scale enterprise, both in Local and Remote reporting modes.
Another important use of ReportViewer in ASP.NET applications is the ability to use the web site authentication over the Reporting Services reports. You can grant permissions over the reports using your ASP.NET application easily without dealing with details in SSRS authentication and authorization.
One of the most useful and undocumented features of the ReportViewer is its ability to consume a LinqDataSource as the ReportDataSource. Though Visual Studio automatically adds an ObjectDataSource when you first add the viewer, this is only useful if you plan on using a DataSet to collect your data from the database. However, as Linq becomes more prevelant for manipulating data, you'll want to investigate tying your reports directly to a DataContext rather than managing DataSet and DataContext objects in the same project.
To Be Included
- Creating a basic report
- Adding ReportViewer to your web application
- Provide data via ObjectDataSource
- Provide data via DataSet, CodeBehind
- Provide data via LinqDataSource and Linq to SQL
Revision number 2, Monday, June 01, 2009 6:33:30 AM by eralper
You must Login to comment.
|
Thu, May 7, 2009 4:09 PM
by Cynthia Jordan
|
I need help with a website using Reportviewer, but I do not have forum rights. Could someone help me with this.
|
|
Thu, Sep 3, 2009 10:10 AM
by suthish nair
|
Thank you, good one
|
|
Thu, Mar 11, 2010 10:46 AM
by Raziq
|
That's true, I've been searching all over the internet did not find any documentation about Report Viewer control not even in best selling ASP.NET book. This could be a great help for me if the author include the following topics as i'm building web application and a reporting solution for L&T MPS division. * Creating a basic report
* Adding ReportViewer to your web application
* Provide data via LinqDataSource and Linq to SQL
|
|
Fri, Apr 2, 2010 2:02 AM
by Abdul Jabbar Patel
|
* Creating a basic report * Adding ReportViewer to your web application * Provide data via ObjectDataSource * Provide data via DataSet, CodeBehind * Provide data via LinqDataSource and Linq to SQL All this topics will be much help full for me. i am also looking like this.
thanks
|
|
Thu, Feb 24, 2011 1:04 PM
by g.hinman
|
Where is the rest of the article?
|
|
Wed, Feb 6, 2013 11:41 AM
by anilreddy128
|
Browser related: If supporting firefox, we need to take care of session time. If we have larger session time, reportviewer gets into flickering issues. When I had that issue, I made session time to 10000 and it started working fine......Not sure about the reason for this.....
|