Skip to content

Report Viewer toolbar font #1342

Closed
Closed

Description

@itg-assistant

Ewan Walker asked 2018-01-30 08:35:21 UTC

Does anyone know of a way of changing the default font used on the tool bars so it matches that used on the report?

I think I may have a possible solution using Viewer.CssClass.

How do I get the CssClass function to find the embedded css file?

Thanks for your help

Activity

  1. itg-assistant commented on Jun 12, 2026

    @itg-assistant
    Author

    Luca answered 2018-02-02 21:41:56 UTC

    I don't know if the ReportViewer ASP.NET object can reach the toolbar. You can set the font in OnInit or OnLoad:

    viewer.Font.Name = "Verdana";
    viewer.Font.Size = 30;

    Or you can set the css class:

    viewer.CssClass = "viewer-mystyle";

    To define the css simply use a css file and link it in default.html like a standard html page.

  2. itg-assistant commented on Jun 12, 2026

    @itg-assistant
    Author

    Ewan Walker answered 2018-02-05 08:24:12 UTC

    Hi Luca

    Thanks.

    What threw me was as you type, viewer.Font appears as only having {get}, however viewer.Font.Name appears as  FontInfo {get, set}.

    However just setting the Font Name works everywhere on the control, which includes  both toolbars and report parameters, including the report loading spinner and the new print control.

    Now this could be because I created a css file for the SSRS to match that of our rebrand, which you link in the SSRS WebConfig.

    https://social.msdn.microsoft.com/Forums/sqlserver/en-US/7e4478fb-932c-4762-b271-fc05afe95add/change-reportviewer-style?forum=sqlreportingservices

    The font used on the actual reports stays unchanged which makes sense as this needs changing using  Visual Studio report designer, for each report

  3. itg-assistant commented on Jun 12, 2026

    @itg-assistant
    Author

    Ewan Walker answered 2018-05-03 10:23:31 UTC

    Since upgrading to Windows 10 1803 the font no longer works. Is this an issue with SSRS and Windows 10 1803?

    Just Checking

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    GeneralQuestions, how-tos and everything else.

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions