Skip to content

Commit 2d280ca

Browse files
authored
Merge pull request #1487 from syncfusion-content/905221
CurrentUser API UG documentation
2 parents 190bb63 + 3dfcd7a commit 2d280ca

File tree

2 files changed

+40
-0
lines changed

2 files changed

+40
-0
lines changed

wpf-toc.html

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1528,6 +1528,7 @@
15281528
<li><a href="/wpf/Pdf-Viewer/how-to/disable-toolbar-items">Disable toolbar items</a></li>
15291529
<li><a href="/wpf/Pdf-Viewer/how-to/disable-the-annotations-selection">Disable the annotations selection</a></li>
15301530
<li><a href="/wpf/Pdf-Viewer/acquiring-total-number-of-pages">Acquire total number of pages</a></li>
1531+
<li><a href="/wpf/Pdf-Viewer/how-to/Changing-the-Current-User">Change the Current User in PdfViewer</a></li>
15311532
<li><a href="/wpf/Pdf-Viewer/changing-the-color-of-the-loading-indicator">Change the color of the Loading Indicator</a></li>
15321533
<li><a href="/wpf/Pdf-Viewer/how-to/change-the-selection-color-of-annotations">Change the selection color of the annotations</a></li>
15331534
<li><a href="/wpf/Pdf-Viewer/changing-the-text-displayed-in-the-loading-indicator">Change the text displayed in the loading indicator</a></li>
Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
---
2+
layout: post
3+
title: Change the Current user in PdfViewer | Syncfusion
4+
description: Learn about how to Change the CurrentUser in Syncfusion WPF Pdf Viewer control using CurrentUser property.
5+
platform: wpf
6+
control: PDF Viewer
7+
documentation: ug
8+
---
9+
10+
# Change the CurrentUser in WPF Pdf Viewer
11+
12+
The PDF Viewer allows you to change the CurrentUser. If the CurrentUser property is not set, it defaults to the system user name. When you set the CurrentUser, the changes will be reflected in the author property of newly added annotations. The following code example illustrates how to set the CurrentUser:
13+
14+
{% tabs %}
15+
{% highlight C# %}
16+
17+
//Initialize PDF Viewer.
18+
PdfViewerControl pdfViewer = new PdfViewerControl();
19+
//Load the PDF.
20+
pdfViewer.Load("Sample.pdf");
21+
22+
//Changing the CurrentUser of document
23+
pdfViewer.CurrentUser = "set the name here";
24+
{% endhighlight %}
25+
26+
27+
28+
{% highlight vbnet %}
29+
30+
'Initialize PDF Viewer.
31+
Private pdfViewer As New PdfViewerControl()
32+
'Load the PDF.
33+
pdfViewer.Load("Sample.pdf")
34+
35+
'Changing the CurrentUser of document
36+
pdfViewer.CurrentUser = "set the name here";
37+
38+
{% endhighlight %}
39+
{% endtabs %}

0 commit comments

Comments
 (0)