windowsforms-devexpress-dot-xtrapdfviewer-dot-pdfviewer-890d404f.md
Gets or sets the path to the PDF file, which is currently opened in the PdfViewer control.
Namespace : DevExpress.XtraPdfViewer
Assembly : DevExpress.XtraPdfViewer.v25.2.dll
NuGet Package : DevExpress.Win.PdfViewer
[DefaultValue("")]
public string DocumentFilePath { get; set; }
<DefaultValue("")>
Public Property DocumentFilePath As String
| Type | Default | Description |
|---|---|---|
| String | String.Empty |
A string value containing the file path.
|
The following code snippets (auto-collected from DevExpress Examples) contain references to the DocumentFilePath 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.
winforms-pdf-viewer-operate-pdf-content-at-runtime/CS/WindowsFormsApplication1/MainForm.cs#L54
private void barButtonItem1_ItemClick(object sender, ItemClickEventArgs e) {
string path = pdfViewer1.DocumentFilePath;
TextViewerForm textViewer = new TextViewerForm();
how-to-custom-draw-in-pdf-viewer/CS/PDF_Viewer/Form1.cs#L41
{
processor.LoadDocument(Control.DocumentFilePath);
foreach (var rect in rectangles)
winforms-pdf-viewer-operate-pdf-content-at-runtime/VB/WindowsFormsApplication1/MainForm.vb#L57
Private Sub barButtonItem1_ItemClick(ByVal sender As Object, ByVal e As ItemClickEventArgs)
Dim path As String = pdfViewer1.DocumentFilePath
Dim textViewer As TextViewerForm = New TextViewerForm()
how-to-custom-draw-in-pdf-viewer/VB/PDF_Viewer/Form1.vb#L39
Using processor As PdfDocumentProcessor = New PdfDocumentProcessor()
processor.LoadDocument(Control.DocumentFilePath)
For Each rect In rectangles
See Also