Skip to content

Commit a6f1f5c

Browse files
998464: Added the documentation for the Blazor Organize Pages
1 parent d5b9f87 commit a6f1f5c

34 files changed

+911
-0
lines changed

Document-Processing-toc.html

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -740,6 +740,16 @@
740740
</ul>
741741
</li>
742742
<li> <a href="/document-processing/pdf/pdf-viewer/blazor/form-filling">Form Filling</a></li>
743+
<li><a href="/document-processing/pdf/pdf-viewer/blazor/organize-pdf">Organize Pages</a>
744+
<ul>
745+
<li><a href="/document-processing/pdf/pdf-viewer/blazor/organize-pages/overview">Overview</a></li>
746+
<li><a href="/document-processing/pdf/pdf-viewer/blazor/organize-pages/programmatic-support">Programmatic Support</a></li>
747+
<li><a href="/document-processing/pdf/pdf-viewer/blazor/organize-pages/ui-interactions">UI Interactions</a></li>
748+
<li><a href="/document-processing/pdf/pdf-viewer/blazor/organize-pages/toolbar">Toolbar</a></li>
749+
<li><a href="/document-processing/pdf/pdf-viewer/blazor/organize-pages/mobile-view">Mobile View</a></li>
750+
<li><a href="/document-processing/pdf/pdf-viewer/blazor/organize-pages/events">Events</a></li>
751+
</ul>
752+
</li>
743753
<li> <a href="/document-processing/pdf/pdf-viewer/blazor/print">Print</a></li>
744754
<li> <a href="/document-processing/pdf/pdf-viewer/blazor/document-security-overview">Document security</a>
745755
<ul>
Lines changed: 101 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,101 @@
1+
---
2+
layout: post
3+
title: Organize Pages Events in Blazor PDF Viewer | Syncfusion
4+
description: Learn how to organize pages Events in the PDF Viewer, including rotating, rearranging, inserting, deleting, and copying pages on mobile devices.
5+
platform: document-processing
6+
control: SfPdfViewer
7+
documentation: ug
8+
---
9+
10+
# Organize Pages Events in Blazor PDF Viewer
11+
12+
The PDF Viewer provides events to track and respond to actions within the page organizer, allowing for the customization of page manipulation features.
13+
14+
## PageOrganizerSaveRequested Event
15+
16+
The `PageOrganizerSaveRequested` event is triggered when a save action is performed in the page organizer.
17+
18+
- Occurs when the **Save as** button in the page organizer toolbar is clicked after modifying the document structure.
19+
20+
The event arguments provide the necessary information about the save event:
21+
22+
- `FileName`: The name of the currently loaded PDF document.
23+
- `DownloadDocument`: A base64 string of the modified PDF document data.
24+
- `Cancel`: A boolean that, when set to `true`, prevents the default save action from proceeding.
25+
26+
{% tabs %}
27+
{% highlight razor %}
28+
29+
@page "/"
30+
<SfPdfViewer2 DocumentPath="https://cdn.syncfusion.com/content/pdf/pdf-succinctly.pdf"
31+
Height="100%"
32+
Width="100%">
33+
<PdfViewerEvents PageOrganizerSaveRequested="SavePages"></PdfViewerEvents>
34+
</SfPdfViewer2>
35+
36+
@code {
37+
private void SavePages(PageOrganizerSaveEventArgs args) {
38+
Console.WriteLine("Saved File Name : " + args.FileName.ToString());
39+
}
40+
}
41+
42+
{% endhighlight %}
43+
{% endtabs %}
44+
45+
## PageOrganizerZoomChanged Event
46+
47+
The `PageOrganizerZoomChanged` event is triggered when the zoom level of the page organizer is changed.
48+
49+
- This event is fired when the user interacts with the zoom slider in the page organizer. The `ShowImageZoomingSlider` property in `PageOrganizerSettings` must be set to `true` for the slider to be visible.
50+
51+
Event arguments:
52+
53+
- `PreviousZoom`: The previous zoom value.
54+
- `CurrentZoom`: The current zoom value.
55+
56+
{% tabs %}
57+
{% highlight razor %}
58+
59+
@page "/"
60+
<SfPdfViewer2 DocumentPath="https://cdn.syncfusion.com/content/pdf/pdf-succinctly.pdf"
61+
Height="100%"
62+
Width="100%">
63+
<PdfViewerEvents PageOrganizerZoomChanged="ZoomChange"></PdfViewerEvents>
64+
</SfPdfViewer2>
65+
66+
@code {
67+
private void ZoomChange(PageOrganizerZoomChangedEventArgs args) {
68+
Console.WriteLine("Current Zoom : " + args.CurrentZoom);
69+
}
70+
}
71+
72+
{% endhighlight %}
73+
{% endtabs %}
74+
75+
## PageOrganizerVisibilityChanged Event
76+
77+
The `PageOrganizerVisibilityChanged` event is triggered when the page organizer dialog visibility is changed.
78+
79+
{% tabs %}
80+
{% highlight razor %}
81+
82+
@page "/"
83+
<SfPdfViewer2 DocumentPath="https://cdn.syncfusion.com/content/pdf/pdf-succinctly.pdf"
84+
Height="100%"
85+
Width="100%" PageOrganizerVisibilityChanged="VisibleChanged">
86+
</SfPdfViewer2>
87+
88+
@code {
89+
private void VisibleChanged(bool isVisible) {
90+
Console.WriteLine("Organize Dialog Visibility : " + isVisible.ToString());
91+
}
92+
}
93+
94+
{% endhighlight %}
95+
{% endtabs %}
96+
97+
## Related event documentation
98+
99+
- Overall Viewer events: [Event](../events)
100+
- Annotation events: [Annotation events](../annotation/events)
101+
- Form designer events: [Form field events](../form-designer/events)
457 KB
Loading
254 KB
Loading
51.2 KB
Loading
254 KB
Loading
253 KB
Loading
253 KB
Loading
255 KB
Loading
50.2 KB
Loading

0 commit comments

Comments
 (0)