Phone (01457) 858877 or email
This blog shows you how to use CSS style sheets to change the default appearance of the Reporting Services parameter strip.
Many people on our Reporting Services courses ask if they can customise the appearance of the SSRS parameter bar. The answer is yes ... but see this hint.
I'd recommend not customising the parameters bar. You'll spend days (weeks?) playing about with the CSS style sheets trying to get everything right - and even then you're vulnerable to Microsoft releasing a new version of SSRS which will change the way things work. Far better to manage your users' expectations!
However, I recognise that there are times when you really do need to change the default parameters bar appearance (well, I think I do) from the slightly dull default:
The parameters bar as it appears by default.
However, some changes aren't necessarily an improvement!
Here we've applied a pink style to the parameter bar.
Still interested? You'll need to learn how to configure Reporting Services to use a different style sheet, and then create this extra style sheet - all of this is described in the rest of this blog.
You'll need to know CSS to customise the parameters bar. You can see a tutorial on CSS here.
Somewhere inside your report server is a folder containing a configuration file called rsreportserver.config. On my computer the folder can be found at:C:\Program Files\Microsoft SQL Server\MSRS10_50.SQL2008R2\Reporting Services\ReportServer
This is because I have a named instance of SQL Server called SQL2008R2 installed, and more than one copy of Reporting Services running. Your folder path might be easier to find.
If you edit this file, you can tell SSRS to use an additional style sheet:
Here we're telling SSRS to use a style sheet called pink.css.
What you now need to do is to create this style sheet!
The default style sheet on which reports are based is complicated, to say the least, and you don't want to start from scratch. Fortunately, Microsoft have provided a template for you to use called HtmlViewer.css. You can find this in the Styles subfolder of the folder shown above:
The template provided for editing styles. Here I've already copied it to create the pink.css style sheet.
All that you need to do is to copy and paste the
HtmlViewer.css template, and rename it to create your
I've no intention of creating a full tutorial for style sheets for SSRS, but here are some styles you may like to find and customise:
|Style||Controls appearance of|
|msrs-topBreadcrumb||The top links of the report (Home, My Subscriptions, etc.).|
|The parameters strip itself.|
|SplitterNormal||The line between the parameters bar and the paging toolbar below it.|
|The bar containing tools to move between pages, zoom in, etc.|
Just to give a flavour of what's possible, here's my customised parameter bar:
The parameter bar after I'd had my evil way with it.
Here is a sample of the CSS to achieve this, with some comments :
/* make background owly pink! */
border: 1px solid maroon;
widen labels for parameters
and change font colour
And with that, I leave you to your own devices. Good luck!
Comments on this blog
This blog currently has no comments.