Skip to main content

DocumentPreviewControl.HiddenExportFormats Property

Provides access to the collection of export formats that cannot be used to export the document. This is a dependency property.

Namespace: DevExpress.Xpf.Printing

Assembly: DevExpress.Xpf.Printing.v23.2.dll

NuGet Package: DevExpress.Wpf.Printing

Declaration

public ObservableCollection<ExportFormat> HiddenExportFormats { get; set; }

Property Value

Type Description
ObservableCollection<ExportFormat>

The collection of ExportFormat enumeration values, specifying the hidden export formats.

Remarks

The DocumentPreviewControl allows users to export the currently displayed document to various third-party formats. To prohibit exporting the document to a specific format, add this format to the HiddenExportFormats collection.

using System.Windows;
using DevExpress.XtraPrinting;
//... 

private void DocumentPreview_Loaded(object sender, RoutedEventArgs e) {
    XtraReport1 report = new XtraReport1();
    documentPreview.DocumentSource = report;
    report.CreateDocument();
    documentPreview.HiddenExportFormats.Add(ExportFormat.Pdf);
}

The following code snippet (auto-collected from DevExpress Examples) contains a reference to the HiddenExportFormats property.

Note

The algorithm used to collect these code examples remains a work in progress. Accordingly, the links and snippets below may produce inaccurate results. If you encounter an issue with code examples below, please use the feedback form on this page to report the issue.

See Also