Log In
Home
Support
Demos
Documentation
Blogs
Training
Webinars
[Expand]General Information
[Collapse]WinForms Controls
  Prerequisites
 [Expand]What's Installed
 [Expand]Build an Application
 [Collapse]Controls and Libraries
  [Expand]Forms and User Controls
  [Expand]Messages, Notifications and Dialogs
  [Expand]Editors and Simple Controls
  [Expand]Ribbon, Bars and Menu
  [Expand]Application UI Manager
  [Expand]Docking Library
  [Expand]Data Grid
  [Expand]Vertical Grid
  [Expand]Pivot Grid
  [Expand]Tree List
  [Expand]Chart Control
  [Expand]Diagrams
  [Expand]Gauges
  [Expand]Map Control
  [Expand]Scheduler
  [Expand]Spreadsheet
  [Expand]Rich Text Editor
  [Expand]Spell Checker
  [Expand]Form Layout Managers
  [Expand]Navigation Controls
  [Collapse]Printing-Exporting
   [Expand]Product Information
   [Expand]Getting Started
   [Expand]Fundamental Concepts
   [Expand]Concepts
   [Collapse]Examples
    [Expand]Print Preview
    [Collapse]Using Bricks
      How to: Use Bricks of Different Types
      How to: Use Modifiers of BrickGraphics
      How to: Draw a Line Brick
      How to: Modify Brick Appearance using Styles
      How to: Unite Bricks into a Non-Separable Group
      How to: Insert a Page Break between Two Bricks
      How to: Create a Non-Printable Brick
      How to: Create a Custom Brick Inherited from a Standard Brick
      How to: Create a Custom Brick Implementing the IBrick Interface
    [Expand]Using Printing Links
    [Expand]Page Header and Footer
    [Expand]Printing DevExpress Controls
    [Expand]Exporting
    [Expand]Miscellaneous
  [Expand]PDF Viewer
   Reporting
  [Expand]Snap
  [Expand]TreeMap Control
 [Expand]Common Features
  Get More Help
 [Expand]API Reference
[Expand]ASP.NET Controls and MVC Extensions
[Expand]ASP.NET Bootstrap Controls
[Expand]ASP.NET Core Bootstrap Controls
[Expand]WPF Controls
[Expand]Xamarin Controls
[Expand]Windows 10 App Controls
[Expand]Document Server
[Expand]Reporting
[Expand]Report Server
[Expand]Dashboard
[Expand]eXpressApp Framework
[Expand]CodeRush
[Expand]CodeRush Classic
[Expand]Cross-Platform Core Libraries
[Expand]Tools and Utilities
 End-User Documentation

How to: Use Modifiers of BrickGraphics

This example demonstrates how to use report modifiers. To get more information on modifiers, refer to the Document Sections topic. We are going to create a sample report containing Detail, DetailHeader and MarginalHeader sections.

  1. Start a new Windows Application project in Visual Studio.NET.
  2. Add the PrintingSystem component to a project.
  3. Initiate report creation.

  4. To create the MarginalHeader section, set the BrickGraphics.Modifier property of the BrickGraphics to MarginalHeader. The following code adds the date, page count and the current page number to the section.

  5. To create a DetailHeader section, set the BrickGraphics.Modifier property of the BrickGraphics to DetailHeader. The following code adds a column caption to the section.

  6. To create a Detail section, set the BrickGraphics.Modifier property of the BrickGraphics to Detail. The following code adds 100 numbered items to the section.

  7. Finish report creation by calling the PrintingSystemBase.End method, and show the Preview form to ensure that everything has been done correctly.

    The resulting report is shown in the following image.

Show Me

A complete sample project is available in the DevExpress Code Examples database at http://www.devexpress.com/example=E119.

Expanded See Also

How would you rate this topic?​​​​​​​