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
   [Collapse]Fundamental Concepts
     Document Creation Approaches
     Classes Hierarchy: Bricks
     Class Hierarchy: Printing
   [Expand]Concepts
   [Expand]Examples
  [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]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]Cross-Platform Core Libraries
[Expand]Tools and Utilities
 End-User Documentation

Document Creation Approaches

This topic demonstrates how you can print and/or export a visual control or a non-visual component using printing links added to a Printing System collection.

This topic consists of the following sections.

Expanded Print Standard Windows Forms Controls

To print standard Windows Forms controls, the XtraPrinting Library provides the following standard link types (all deriving from the base Link class).

  • ListViewLink - a link to print the System.Windows.Forms.ListView control.
  • RichTextBoxLink - a link to print the System.Windows.Forms.RichTextBox control.
  • TreeViewLink - a link to print the System.Windows.Forms.TreeView control.
  • DataGridLink - a link to print the System.Windows.Forms.DataGrid control.

For code samples, see How to: Print a TreeView Control and How to: Print a DataGrid Control.

Expanded Print DevExpress Controls

The following DevExpress controls implement the IPrintable interface and can be printed using the PrintableComponentLink.

The following web controls implement the IPrintable interface and can be directly exported to a stream or response in various document formats using the methods of their corresponding exporter objects.

For more information, see How to: Use the PrintableComponentLink to Print DevExpress Controls.

Expanded Print Custom Components

To print your custom component using Printing System, this component should implement the IPrintable interface, after which you can print it using the PrintableComponentLink class.

For more information, see How to: Create a Printable ListView Descendant Implementing the IPrintable Interface.

Expanded Additional Customization

The Link class provides a set of events, each intended to create a specific document section.

In any of these event handlers, you can customize the CreateAreaEventArgs.Graph property, which provides access to a Brick Graphics object that is used to create bricks of different types.

Handle these events in the following order to create and/or modify your document sections.

After finishing modifying document sections, call the Link.CreateDocument method (to create a paginated document that is ready to be previewed, printed or exported) or the Link.ShowPreview method (which creates a document and then shows it in a Print Preview form).

For more information, see How to: Use Link Events (Complete Sample).

Expanded See Also

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