PrintHelper Class
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Helper class used to simplify document printing. It allows you to render a framework element per page.
public class PrintHelper : IDisposable
type PrintHelper = class
interface IDisposable
Public Class PrintHelper
Implements IDisposable
- Inheritance
-
PrintHelper
- Implements
Remarks
Constructors
PrintHelper(Panel, PrintHelperOptions, DispatcherQueue) |
Initializes a new instance of the PrintHelper class. |
PrintHelper(Panel, PrintHelperOptions) |
Initializes a new instance of the PrintHelper class. |
Properties
ApplicationContentMarginLeft |
Gets or sets the percentage of the app's margin width. |
ApplicationContentMarginTop |
Gets or sets the percentage of the app's margin height. |
DispatcherQueue |
Gets or sets which DispatcherQueue is used to dispatch UI updates. |
Methods
AddFrameworkElementToPrint(FrameworkElement) |
Adds an element to the list of elements to print. |
ClearListOfPrintableFrameworkElements() |
Removes all elements from the list of elements to print. |
Dispose() |
Release associated resources |
RemoveFrameworkElementToPrint(FrameworkElement) |
Removes an element from the list of elements to print. |
ShowPrintUIAsync(String, Boolean) |
Starts the print task. |
ShowPrintUIAsync(String, PrintHelperOptions, Boolean) |
Starts the print task. |
Events
OnPreviewPagesCreated |
Occurs after print preview pages are generated. |
OnPrintCanceled |
Occurs when a print is canceled by the user. |
OnPrintFailed |
Occurs when a print fails. |
OnPrintSucceeded |
Occurs when a print was successful. |