Back to Devexpress

PdfViewerControl.Document Property

wpf-devexpress-dot-xpf-dot-pdfviewer-dot-pdfviewercontrol-f3c2a57f.md

latest2.5 KB
Original Source

PdfViewerControl.Document Property

Returns the current PDF document.

Namespace : DevExpress.Xpf.PdfViewer

Assembly : DevExpress.Xpf.PdfViewer.v25.2.dll

NuGet Package : DevExpress.Wpf.PdfViewer

Declaration

csharp
public IPdfDocument Document { get; }
vb
Public ReadOnly Property Document As IPdfDocument

Property Value

TypeDescription
IPdfDocument

A IPdfDocument object that is the current PDF document.

|

The following code snippet (auto-collected from DevExpress Examples) contains a reference to the Document 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.

wpf-pdf-viewer-replace-standard-command-with-custom-command/CS/MainWindow.xaml.cs#L45

csharp
bool CanZoomIn() {
    return Control != null && Control.Document != null && Control.ZoomFactor < factors[factors.Count - 1];
}

wpf-pdf-viewer-replace-standard-command-with-custom-command/VB/MainWindow.xaml.vb#L64

vb
Private Function CanZoomIn() As Boolean
    Return Me.Control IsNot Nothing AndAlso Me.Control.Document IsNot Nothing AndAlso Me.Control.ZoomFactor < Me.factors(Me.factors.Count - 1)
End Function

See Also

PdfViewerControl Class

PdfViewerControl Members

DevExpress.Xpf.PdfViewer Namespace