Q: How to make the darn parameter drop-down list wider in HTMLViewer? HTMLViewer is the Report Manager control that displays the report when you view the report.
A: HTMLViewer supports limited customization via a CSS stylesheet.
- Copy HTMLViewer.css to MyHTMLViewer.css in the same folder (Reporting Services\ReportServer\Styles). Note that the actual folder path varies between SQL Server versions.
- Add the following CSS style to MyHTMLViewer.css
SELECT {
font-size: 8pt;
font-family: Verdana;
width:200px
}
As a result, all SELECT elements on the page (all dropdowns, such as parameter prompts, zoom, export) will pick up these settings.
-
Configure the server to use the custom stylesheet by one of these options:
- If you want to apply the custom styles to all reports, add a new HTMLViewerStyleSheet element to the rsreportserver.config file, such as:
<Configuration>
…
<HTMLViewerStyleSheet>MyStyleSheet</HTMLViewerStyleSheet>
…
</Configuration>
Note that due to an unfortunate bug, the HTMLViewerStyleSheet setting doesn’t work with February CTP of SQL Server 2008 but it will be fixed in the final release.
- Use the rs:Stylesheet device setting to apply the custom style to given report only, such as:
http://localhost/ReportServer?/AdventureWorks Sample Reports/Product Line Sales&rs:Command=Render&rc:Stylesheet=MyStylesheet



Hi. Thank you for your lightning response π
Is is possible to use multiple css files?
That way i can keep all current css classes and settings and just “add” this one?
I’m afraid this solution has no effect…I did exactly as you instructed but nothing has changed in the parameters fields.
what i do notice is that some of the fields did grow wider, but only those who now have the “” on them in the beginning…where did that come from ? π
some of the parameters are dependant.those who are not dependant are affected by the change (they have “” on them in the beginning…is the css class for dependant parameters different somehow?
Hi,
Interesting post!
I tried setting the direction attribute (for body) to rtl (right-to-left, for langauges such as hebrew and arabic) in order for the parameter inputs to show from right to left, but to no avail.
Do you know if it’s possible to do it with CSS in SSRS?
All SELECT elements in the HTML viewer should pick up these settings.
Saggi,
I don’t know. I don’t know CSS that well. If CSS can do it, I don’t see any reason this won’t work with SSRS.
Microid,
You can have as many CSS files as you want but the report link can use only one.
Thank you for noting the issue with Feb release of RS2008. I’ve spent 2hrs trying to figure out why my custom css wasn’t working with it.