Using SoftArtisans OfficeWriter with SQL Server Reporting Services 2005
page 5 of 10
by Mike Campbell
Average Rating: This article has not yet been rated.
Views (Total / Last 10 Days): 38610/ 49

Creating a Sample Report

You are now ready to create a simple Reporting Services report that we can use to see everything in action.  To create this sample report follow these steps.

1.      Open Visual Studio 2005 and select File | New | Project.  Select the Business Intelligence Projects project type and then select the Report Server Project Wizard as depicted in Figure 1.  Give your project a name, like SampleReport, and click OK.

Figure 1


2.      On the Report Wizard Welcome screen (if you get one), just click Next and then create a new data source pointing to your AdventureWorks database.  To do this, give your data source a Name of AdventureWorks, then click the Edit button and provide the needed configuration.  Once completed, your results should look similar to those in Figure 2.  Click Next to continue.

Figure 2

3.      Paste the following SQL statement into the Query string box in the Report Wizard and click Next.

Listing 1


  loc.Name [Location],
  prod.ProductNumber [Part Number],
  prod.Name [Part name],
  prod.ReorderPoint [Reorder Point],
  inv.Quantity [Current Count],
  prod.ReorderPoint - inv.Quantity [Deficit]
  Production.ProductInventory inv
  INNER JOIN Production.Product prod ON prod.ProductID = inv.ProductID
  INNER JOIN Production.Location loc ON inv.LocationID = loc.LocationID
  inv.Quantity < prod.ReorderPoint AND
  inv.Shelf <> 'N/A' AND
  inv.LocationID = @location
  1,5 DESC

4.      Click Next again to create a tabular report and then move all of the available fields to the Details section of the Table designer.  Now click Next twice.

5.      In the Choose the Deployment Location page, specify the location of your Report Server as well as any folder you would like to use for organization.  I just chose the defaults.  Click Next and then click Finish.

Once the Wizard completes the process of creating your report, go ahead and select the Preview tab from the designer within Visual Studio 2005.  Then enter the literal value "20" (minus the quotes) into the location field and press the View Report button.

View Entire Article

User Comments

Title: RA   
Name: SA
Date: 2008-04-24 12:05:05 PM
Can Office writer help in renaming the sheet names once the report is exported from Report server
Title: Dynamic Rendering   
Name: ST
Date: 2007-10-01 6:14:24 AM

I have tested the code given on the above. During the render, I get this exception "Client found response content type of '', but expected 'text/xml'.
The request failed with an empty response." on the function Render(...). What am I missing on here?

Title: RE: Dynamic Rendering (@giovanni)   
Name: Michael K. Campbell
Date: 2006-08-31 8:37:50 PM
Giovanni, glad you liked the article.

Make sure you've got the SoftArtisans SAXW6NET.dll copied in to your /bin/ directory - that will likely be your biggest issue.

I also generated a VB.NET conversion of the default.aspx.cs page, and posted it up in my uploads section: (but you'll need to do wire-ups for code-behind/partial classing etc...)

Title: Render Dynamic   
Name: GIovanni Rivas
Date: 2006-08-31 6:06:35 PM
Hi, thx for the article, but i tryed to copy the code in cs that you give here and doesn't work, i have to so all the references to the Interop libary for excel and the methodthat you are calling there with the arguments doesn't exist. am i missing something, do you havea code in that could work like this. thx
if you can reply at

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

©Copyright 1998-2024  |  Page Processed at 2024-04-13 12:30:57 PM  AspAlliance Recent Articles RSS Feed
About ASPAlliance | Newsgroups | Advertise | Authors | Email Lists | Feedback | Link To Us | Privacy | Search