Building Reports using ASP.NET and Crystal Reports - Part 5 - Creating Reports as a Web Service
page 1 of 6
Published: 28 Sep 2009
Abstract
In this article, Vince walks the user through the process of creating a Crystal Report as a web service and then creating a web site to consume the service. After providing a short introduction, he examines the relevant steps which includes the creation of a web service, adding crystal reports file, and establishing database connectivity using Visual Studio 2008. Towards the end of the article, he examines the creation of a web site with the help of relevant source code and screenshots.
by Vince Varallo
Feedback
Average Rating: This article has not yet been rated.
Views (Total / Last 10 Days): 34956/ 83

Introduction

This is the fifth article of a series that uses ASP.NET and Crystal Reports to build reports using the Adventure Works Sample Database.  Before reading this article it would be helpful to read Part 1, Part 2, Part 3, and Part 4, but it is not required.  At a minimum you should read Part 1. This article creates a web service that delivers the Invoice report developed in Part 1. The article then covers creating a web site to consume the web service, filter the report, and display the report to the user using the Crystal Reports Viewer control. Reading Part 1 would be most beneficial because I will use the Invoice.rpt file developed in that article to create the web service. You can also download the code here to get the report file.

Before you begin you will need to have installed Visual Studio 2008 with Crystal Reports for .NET.  The samples are written in Visual Studio 2008 but they will work with Visual Studio 2005 also.  You also will need to download the AdventureWorks sample database for SQL Server 2008.  Download and install the SQL2008.AdventureWorks_All_Databases.x86.msi file. If you do not have SQL Server 2008 you can use SQL Server 2005, but you'll need to download the 2005 AdventureWorks samples.

The goal of this article is to create a web page that looks like the following image. 

As stated earlier, this is the same report that was created in Part 1 of this series. The user can select a customer from the drop down list and preview all the invoices for the selected customer.


View Entire Article

User Comments

Title: Possibility in crystal report 2010   
Name: thantowi jauhari
Date: 2011-09-14 11:42:35 AM
Comment:
is it work for crystal report 2010 ??
Title: Crystal Reports Hosting   
Name: crystaly
Date: 2010-11-24 1:43:36 AM
Comment:
Just found your nice article. thx
Title: Crystal Rpts Web Service   
Name: Doug
Date: 2010-10-14 4:57:56 AM
Comment:
Hello Vince,
I was wondering if you had issues with load times while downloading the web service everytime you open the browser again. It takes 15 seconds to run my report the first time then 2 seconds everytime thereafter. Thoughs?
Doug
Title: ASP.NET Crystal Reports Hosting   
Name: rajanish
Date: 2009-10-23 1:27:06 AM
Comment:
good article thanks
if i have more than one reports(.rpt) in web service then how we can call dynamically from report web site
Title: ASP.NET Crystal Reports Hosting   
Name: Helen
Date: 2009-10-14 1:23:14 PM
Comment:
Excellent Articles!

Nice crystal reports guidance!


___________________________________________________
http://www.webhost4lifereview.com/crystal-report-web-hosting/
Title: Mr.   
Name: Rinoy
Date: 2009-10-13 8:31:30 AM
Comment:
good article thanks
if i have more than one reports(.rpt) in web service then how we can call dynamically from report web site

thanks
rinoy
Title: Mr   
Name: Kirt Darji
Date: 2009-10-07 12:55:13 AM
Comment:
Good Artical

crystle Report not run on live server for that what we have to do.

Product Spotlight
Product Spotlight 



Community Advice: ASP | SQL | XML | Regular Expressions | Windows


©Copyright 1998-2017 ASPAlliance.com  |  Page Processed at 2017-10-17 1:02:07 PM  AspAlliance Recent Articles RSS Feed
About ASPAlliance | Newsgroups | Advertise | Authors | Email Lists | Feedback | Link To Us | Privacy | Search