SSRS 2005 Set SimplePageHeaders on the report instead of the server?

Instead of overriding the existing Excel renderer, what you want to do is supply another renderer that strips out the headers and include this in the list of renderers available to the export menu. You almost have the solution – instead of modifying the current Excel renderer you want to supply another one. There are a couple of tricks here:

  • You must give this renderer a name that is different to the current Excel renderer which has Name="EXCEL" on my system, otherwise you will only see one Excel renderer
  • The displayed name of the renderer will not be the name you called it above, but will simply be Excel as that is the display name supplied by the renderer, so you will see two options called Excel and you won’t know which is the one without page headers.
  • Consequently you must override the name
  • When you override the name, you must specify the language that you are overriding it for. The language value that you set must be valid for the report server computer. For example, if the report server is running on a French operating system, you should specify "fr-FR" as the attribute value. I’m using "en-AU" as I am Australian, you would use "en-US" if you are in USA.

Thus, under the current EXCEL renderer (don’t replace the existing one) in <Render> section of rsreportserver.config, you would insert something like:

<Extension Name="EXCEL (No Header)" Type="Microsoft.ReportingServices.Rendering.ExcelRenderer.ExcelRenderer,Microsoft.ReportingServices.ExcelRendering">
    <OverrideNames>
        <Name Language="en-AU">Excel (No Header)</Name>
    </OverrideNames>
    <Configuration> 
        <DeviceInfo>
            <SimplePageHeaders>True</SimplePageHeaders> 
        </DeviceInfo> 
    </Configuration> 
</Extension>

This will give you two Excel options on the Reporting Services export menu: Excel and Excel (No Header)

Don’t forget to change the language attribute in <OverrideNames> to the language on your report server or both options will simply be called Excel

Leave a Comment