New to Telerik Reporting? Download free 30-day trial

Integrating the WPF Report Viewer in .NET Framework

The quickest way to add a WPF Report Viewer to your WPF project is with the Telerik Report Viewer Window item template.

Telerik Report Viewer Window Item Template

The item template is available in the Add New Item dialog box under the WPF category.

This item template will do the following:

  • Build the project and check that the project is using a compatible .NET Framework version.
  • Open the Add New Report Viewer dialog to choose a report definition for the report viewer.
  • Verify that the project is having all the required references to Telerik UI for WPF and if a reference is missing it will ask you to add them according the Telerik Reporting license.
  • Verify that the required styles are merged in the project App.xaml (Application.xaml for VB.NET).
  • If missing, add the Telerik Reporting references (Telerik.Reporting, Telerik.ReportViewer.Wpf, Telerik.ReportViewer.Wpf.Themes, Telerik.Reporting.XpsRendering).
  • Add a Window with WPF Report Viewer.
  • Setup the viewer's connection depending on selected engine type.
  • Show a summary log that list all of the made changes.

If the selected engine is of remote type (REST Service or Report Server), the item template will:

  • Add a reference to Telerik.Reporting.Services.HttpClient to the current project.
  • Add a reference to System.Net.Http and System.Net.Http.Formatting via NuGet package to the current project.

If the selected engine is REST Service, additionally, it will do the following:

  • Create a new web project that will host the REST service.
  • Register the provided REST service URL into IIS Express virtual directories list.
  • Register all the needed NuGet packages for the REST service.

    In some cases, the solution must be rebuilt in order to restore the NuGet packages and start the REST service project correctly.

See Also

In this article