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
   [Collapse]Concepts
    [Expand]Basic Terms
    [Expand]Print Preview
    [Expand]Exporting
    [Collapse]Miscellaneous
      Watermarks
   [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]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

Watermarks

This document describes watermarks: how they can be accessed, assigned to a document's pages, modified and saved/restored.

For a document's PrintingSystem, you can specify a watermark (via the PrintingSystemBase.Watermark property), which can be represented by either text or a picture, or both (which is specified via the PageWatermark.Text and PageWatermark.Image properties respectively).

A watermark object is represented by an instance of the Watermark class, and it can be assigned to a document using the Watermark.CopyFrom method, as it is demonstrated in the following tutorial: How to: Add a Watermark to a Document.

After a Document has been generated, its Document.Pages contain PageWatermark objects, which can be accessed via the Page.Watermark property.

When a watermark is specified for a document, it is applied to all pages. To specify individual watermarks for particular pages, use the Page.AssignWatermark method, as demonstrated in the following tutorial: How to: Add Different Watermarks to Document Pages .

The Watermark class inherits all its options from the base PageWatermark class. Among these options, the following ones have effect on text watermarks only.

And, the following options have effect on image watermarks only.

Finally, the PageWatermark.ShowBehind property is available for both text and image watermarks.

In Print Preview, access to watermark settings is provided by the Watermark toolbar button and the corresponding menu item, both triggering the following printing system command: PrintingSystemCommand.Watermark.

This command raises the Watermark dialog (similar to the one of the PrintingSystemBase.Watermark property) which is used to specify both text and picture watermark options.

Note that these settings can be saved into an XML-file, memory stream or a system registry, and then be restored from there, using appropriate methods. For a tutorial on this, refer to How to: Save and Restore a Document's Watermark in Print Preview.

To control whether a document's watermarks should be preserved when the document is being exported to RTF, use the FormattedTextExportOptions.ExportWatermarks property.

Expanded See Also

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