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

SoftArtisans OfficeWriter

With OfficeWriter, Reporting Services reports can be designed directly from Word and Excel with the OfficeWriter Designer, a special toolbar that is very easy to use.  This gives Microsoft Office users the ability to modify existing reports without requiring them to wait on developers, open Visual Studio, or even leave Office.  Office users can even create their own reports, but this functionality is disabled by default as most organizations prefer to use OfficeWriter Designer to help create a layer of separation between logic and presentation.  Under this paradigm, developers and IT professionals can create data models by joining data from various sources and placing it into a report definition where business users can modify the presentation of the report data to their heart's content (assuming they have been given necessary permissions).

Once designed, reports created or modified with the OfficeWriter Designer are modified with a special bit of base-64 encoded goodness that is "injected" in to the report's definition file.  On the reporting server, these extra instructions are completely ignored unless the report is requested for export via OfficeWriter's custom rendering extensions.  This means that any existing reports modified by the OfficeWriter Designer will continue to function just as they always did.  In fact, they can still be natively exported to a low-functionality version of Excel.  However, when requested for export via the custom OfficeWriter rendering extensions, the base-64 encoded goodness is used to recreate a native Excel or Word document that faithfully matches the template created in the OfficeWriter Designer.  With this template hydrated on the server, OfficeWriter renders extensions then replaces specialized "data-markers" with actual report data pulled from the datasets defined in the report's RDL file.  The result is a beautiful fusion of Reporting Services data into a completely native Word document or Excel spreadsheet that preserves native formatting and functionality as defined during design.

Even better, because OfficeWriter is just generating native Word and Excel documents on the server and programmatically populating them with Reporting Services data, it is possible to "intercept" rendered reports and use the object models exposed by OfficeWriter to programmatically add embellishments, modifications, and other formatting as desired.  In this way a single Reporting Services report can be customized for individual users or specific regions and needs.  For example, a sales company that wanted to give customized quotes to customers could use a single SSRS report to output data with various parameters, but contact information within the report could easily be switched programmatically for each sales associate creating the report.

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-05-23 6:06:06 PM  AspAlliance Recent Articles RSS Feed
About ASPAlliance | Newsgroups | Advertise | Authors | Email Lists | Feedback | Link To Us | Privacy | Search