Back to Devexpress

Add Items to a Print Preview's Ribbon Toolbar

xtrareports-7070-desktop-reporting-winforms-reporting-winforms-reporting-print-preview-api-and-customization-add-items-to-a-print-previews-ribbon-toolbar.md

latest2.4 KB
Original Source

Add Items to a Print Preview's Ribbon Toolbar

  • Nov 10, 2025
  • 2 minutes to read

This tutorial illustrates how to customize a Print Preview’s ribbon toolbar by adding a new button to it.

Important

Customization options described in this help topic are available to owners of DevExpress WinForms, DXperience, and Universal subscriptions (subscriptions that include DevExpress WinForms UI Controls). The DevExpress Reporting Subscription does not support UI customization in Report Viewer or End-User Report Designer. You can use ReportPrintTool and ReportDesignTool classes to display Print Preview and End-User Report Designer in their default configurations.

Refer to the following help topic for information on subscription options: Installation - Subscriptions that Include Reporting Components.

Tip

See the following tutorial to learn how to add a Print Preview to a WinForms application: Create a Custom Print Preview.

Do the following to customize the ribbon toolbar of a preview form:

  1. Generate the ribbon toolbar for a DocumentViewer by clicking its smart tag and selecting the Create Ribbon Toolbar action.

  2. Click the button in the ribbon’s Document group and select the Add Button action.

  3. Handle the button’s BarItem.ItemClick event and add the required code. The following code opens the current report in End-User Report Designer:

The following image illustrates the result: