Share via


Tutorial: Reduced-Code Web Site Setup with Crystal Reports Using Smart Tasks

Introduction

In this tutorial, you create an ASP.NET Web Site in Visual Studio. Then you add a CrystalReportViewer control to the Web Form, which launches the new Smart Task panel. From Smart Tasks, you create a CrystalReportSource control, and then build a Crystal report. The report is referenced within the CrystalReportSource control.

Throughout this tutorial, you can preview the report three ways:

  • In the embedded Crystal Reports Designer, with the new Preview button in Crystal Reports for Visual Studio.

  • In the Web Form, with dummy data.

    Note

    This preview of the Web Form is the new Design Time Preview feature. For more information, see Design Time Preview.

  • At runtime, when you build and compile the application.

At the end of this tutorial, you switch to HTML view (Source View) and explore the relationship between the CrystalReportViewer control and the CrystalReportSource control, in the new tag-based application model of Visual Studio 2005 or later.

Sample Code

This tutorial comes with Visual Basic and C# sample code that show the completed version of the project. Follow the instructions in this tutorial to create a new project or open the sample code project to work from a completed version.

The sample code is stored in folders that are categorized by language and project type. The folder names for each sample code version are as follows:

  • C# Web Site: CS_Web_ReducedCode_WebSiteSetup
  • Visual Basic Web Site: VB_Web_ReducedCode_WebSiteSetup

To locate the folders that contain these samples, see Tutorials' Sample Code Directory.

In this section: