I was hoping that I could create an xsl file to change background colors and
the like in my report. The DataTransform documentation ain't so great.
After creating the xsl file and uploading it to the server and setting the
DataTransform property no changes were evident, I think it only operates on
xml format or something along those lines. Mainly we use pdf and html
rendering. So now I'm thinking I can apply the xsl and generate different
styles when I deploy the reports and add the drop down style selection to
the web app. Anyone giving their users the ability to pick a report style,
and how are you going about it? Any thoughts?
For Example:
deployment:
msxsl myReport.rdl slate.xsl -xe -o myReport_slate.rdl
msxsl myReport.rdl forest.xsl -xe -o myReport_forest.rdl
Here's an example xsl
<?xml version="1.0"?>
<xsl:stylesheet version="2.0"
xmlns="http://schemas.microsoft.com/sqlserver/reporting/2005/01/reportdefinition"
xmlns:rd="http://schemas.microsoft.com/SQLServer/reporting/reportdesigner"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
xmlns:xs="http://www.w3.org/2001/XMLSchema"
xmlns:msrs="http://schemas.microsoft.com/sqlserver/reporting/2005/01/reportdefinition"
xmlns:fn="http://www.w3.org/2005/xpath-functions"
exclude-result-prefixes="msrs xs fn">
<xsl:output method="xml" standalone="no" omit-xml-declaration ="no"
indent="yes"/>
<xsl:template match="//msrs:FontFamily">
<FontFamily>Tahoma</FontFamily>
</xsl:template>
<xsl:template match="//msrs:BackgroundColor">
<BackgroundColor>SteelBlue</BackgroundColor>
</xsl:template>
<xsl:template match="@.* | node()" priority="-2">
<xsl:copy>
<xsl:apply-templates select="@.* | node()"/>
</xsl:copy>
</xsl:template>
</xsl:stylesheet>Hi, I read your post regarding the use of DataTransform in reporting service. If you make any progress with it, would be kind enough to share it?
Thank You.
Rif'at
EggHeadCafe.com - .NET Developer Portal of Choice
http://www.eggheadcafe.comsql
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment