Databases Reference
In-Depth Information
Figure 12-13
Using the ReportViewer Control
The ReportViewer control is by far the most flexible and, in most cases, the easiest technique for adding
a report to your .NET application user interface. Two separate but very similar controls are available for
.NET Windows forms and ASP.NET Web forms applications. All of the user interface attributes you have
seen in the Report Manager and Designer Preview tab may be managed using properties of the control
and may be set at design time in the properties window, or at runtime using program code.
The ReportViewer controls are client-side control that does not need a SQL Server instance to be used.
The only dependency of the control is the .NET Framework 2.0. To install the Report Server does require
a SQL Server license, however. The controls are redistributable, packaged as an msi .
The source data used by the control can come from any data source, not just SQL Server. The ReportViewer
controls themselves have no knowledge of where the data comes from. Your application brings in the
data from whatever source you choose and makes it available to the ReportViewer controls in the form
of ADO.NET DataTables or custom business objects. The ReportViewer controls don't even know how
to connect to databases or execute queries. By requiring the host application to supply the data, the
Search WWH ::




Custom Search