Skip to content

Commit b223d3f

Browse files
committed
Merge branch 'development' of https://github.com/syncfusion-content/document-processing-docs into EJ2-1014442-ug
2 parents 6580d7d + f80098a commit b223d3f

11 files changed

Lines changed: 702 additions & 53 deletions

File tree

Document-Processing-toc.html

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3122,6 +3122,34 @@
31223122
</li>
31233123
</ul>
31243124
</li>
3125+
<li>
3126+
<li>SmartDataExtractor
3127+
<ul>
3128+
<li>
3129+
<a href="/document-processing/smartdataextractor/smartformrecognizer/net/overview">SmartFormRecognizer</a>
3130+
<li> NET
3131+
<ul>
3132+
<li>
3133+
<a href="/document-processing/smartdataextractor/smartformrecognizer/net/smart-form-recognizer">OverView</a>
3134+
</li>
3135+
<li>
3136+
<a href="/document-processing/smartdataextractor/smartformrecognizer/net/assemblies-required">Assemblies Required</a>
3137+
</li>
3138+
<li>
3139+
<a href="/document-processing/smartdataextractor/smartformrecognizer/net/nuGet-packages-required">NuGet Packages Required</a>
3140+
</li>
3141+
<li>
3142+
<a href="/document-processing/smartdataextractor/smartformrecognizer/net/working-with-recognize-option">Working With Recognize Options</a>
3143+
</li>
3144+
<li>
3145+
<a href="/document-processing/smartdataextractor/smartformrecognizer/net/recognize-forms">Recognize Forms</a>
3146+
</li>
3147+
</ul>
3148+
</li>
3149+
</li>
3150+
</ul>
3151+
</li>
3152+
</li>
31253153
<li>
31263154
<a href="/document-processing/word/overview">Word</a>
31273155
<ul>

Document-Processing/Excel/Spreadsheet/React/Open-Excel-File/from-google-drive.md renamed to Document-Processing/Excel/Spreadsheet/React/open-excel-file/from-google-drive.md

File renamed without changes.

Document-Processing/Excel/Spreadsheet/React/Save-Excel-File/to-google-drive.md renamed to Document-Processing/Excel/Spreadsheet/React/save-excel-file/to-google-drive.md

File renamed without changes.

Document-Processing/PDF/PDF-Library/NET/Working-with-Pages.md

Lines changed: 119 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1590,3 +1590,122 @@ loadedDocument.Close(True)
15901590
{% endtabs %}
15911591

15921592
You can download a complete working sample from [GitHub](https://github.com/SyncfusionExamples/PDF-Examples/tree/master/Pages/Insert-New-Page-in-Existing-PDF-with-Same-Size/.NET).
1593+
1594+
## Page-level actions in PDF documents
1595+
1596+
Added full support for page‑level actions in the .NET PDF library, enabling developers to add, retrieve, edit, and remove actions triggered by PDF page events such as `OnOpen` and `OnClose`.
1597+
1598+
Refer to the following code example to define custom behavior for PDF page‑level actions.
1599+
1600+
{% tabs %}
1601+
1602+
{% highlight c# tabtitle="C# [Cross-platform]" %}
1603+
1604+
using Syncfusion.Pdf;
1605+
using Syncfusion.Pdf.Interactive;
1606+
1607+
// Create a new PDF document.
1608+
using (PdfDocument document = new PdfDocument())
1609+
{
1610+
// Add a page to the document.
1611+
PdfPage page1 = document.Pages.Add();
1612+
document.Actions.AfterOpen =
1613+
// Create and add new JavaScript action to execute when the first page opens
1614+
Page1.Actions.OnOpen = new PdfJavaScriptAction("app.alert(\"Welcome! This page has just been opened.\");");
1615+
// Create and add new URI action to execute when the first page closes
1616+
Page1.Actions.OnClose = new PdfUriAction("http://www.google.com");
1617+
// Add second page to the document.
1618+
PdfPage page2 = document.Pages.Add();
1619+
// Create a sound action
1620+
PdfSoundAction soundAction = new PdfSoundAction("Startup.wav");
1621+
soundAction.Sound.Bits = 16;
1622+
soundAction.Sound.Channels = PdfSoundChannels.Stereo;
1623+
soundAction.Sound.Encoding = PdfSoundEncoding.Signed;
1624+
soundAction.Volume = 0.9f;
1625+
// Set the sound action to execute when the second page opens
1626+
Page2.Actions.OnOpen = soundAction;
1627+
// Create and add new Launch action to execute when the second page closes
1628+
Page2.Actions.OnClose = new PdfLaunchAction("logo.png");
1629+
// Removing the close action on first page
1630+
Page1.Actions.OnClose = null;
1631+
// Removing both open and close actions on second page
1632+
Page2.Actions.Clear(true);
1633+
//Save the document
1634+
document.Save("Output.pdf");
1635+
}
1636+
1637+
{% endhighlight %}
1638+
1639+
{% highlight c# tabtitle="C# [Windows-specific]" %}
1640+
1641+
using Syncfusion.Pdf;
1642+
using Syncfusion.Pdf.Interactive;
1643+
1644+
// Create a new PDF document.
1645+
using (PdfDocument document = new PdfDocument())
1646+
{
1647+
// Add a page to the document.
1648+
PdfPage page1 = document.Pages.Add();
1649+
document.Actions.AfterOpen =
1650+
// Create and add new JavaScript action to execute when the first page opens
1651+
Page1.Actions.OnOpen = new PdfJavaScriptAction("app.alert(\"Welcome! This page has just been opened.\");");
1652+
// Create and add new URI action to execute when the first page closes
1653+
Page1.Actions.OnClose = new PdfUriAction("http://www.google.com");
1654+
// Add second page to the document.
1655+
PdfPage page2 = document.Pages.Add();
1656+
// Create a sound action
1657+
PdfSoundAction soundAction = new PdfSoundAction("Startup.wav");
1658+
soundAction.Sound.Bits = 16;
1659+
soundAction.Sound.Channels = PdfSoundChannels.Stereo;
1660+
soundAction.Sound.Encoding = PdfSoundEncoding.Signed;
1661+
soundAction.Volume = 0.9f;
1662+
// Set the sound action to execute when the second page opens
1663+
Page2.Actions.OnOpen = soundAction;
1664+
// Create and add new Launch action to execute when the second page closes
1665+
Page2.Actions.OnClose = new PdfLaunchAction("logo.png");
1666+
// Removing the close action on first page
1667+
Page1.Actions.OnClose = null;
1668+
// Removing both open and close actions on second page
1669+
Page2.Actions.Clear(true);
1670+
//Save the document
1671+
document.Save("Output.pdf");
1672+
}
1673+
1674+
{% endhighlight %}
1675+
1676+
{% highlight vb.net tabtitle="VB.NET [Windows-specific]" %}
1677+
1678+
Imports Syncfusion.Pdf
1679+
Imports Syncfusion.Pdf.Interactive
1680+
1681+
' Create a new PDF document.
1682+
Using document As New PdfDocument()
1683+
' Add a page to the document.
1684+
Dim page1 As PdfPage = document.Pages.Add()
1685+
' Create and add new JavaScript action to execute when the first page opens
1686+
page1.Actions.OnOpen = New PdfJavaScriptAction("app.alert(""Welcome! This page has just been opened."");")
1687+
' Create and add new URI action to execute when the first page closes
1688+
page1.Actions.OnClose = New PdfUriAction("http://www.google.com")
1689+
' Add second page to the document.
1690+
Dim page2 As PdfPage = document.Pages.Add()
1691+
' Create a sound action
1692+
Dim soundAction As New PdfSoundAction("Startup.wav")
1693+
soundAction.Sound.Bits = 16
1694+
soundAction.Sound.Channels = PdfSoundChannels.Stereo
1695+
soundAction.Sound.Encoding = PdfSoundEncoding.Signed
1696+
soundAction.Volume = 0.9F
1697+
' Set the sound action to execute when the second page opens
1698+
page2.Actions.OnOpen = soundAction
1699+
' Create and add new Launch action to execute when the second page closes
1700+
page2.Actions.OnClose = New PdfLaunchAction("logo.png")
1701+
' Removing the close action on first page
1702+
page1.Actions.OnClose = Nothing
1703+
' Removing both open and close actions on second page
1704+
page2.Actions.Clear(True)
1705+
' Save the document
1706+
document.Save("Output.pdf")
1707+
End Using
1708+
1709+
{% endhighlight %}
1710+
1711+
{% endtabs %}
Lines changed: 59 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,59 @@
1+
---
2+
title: Assemblies required for SmartFormRecognizer| Syncfusion&reg;
3+
description: Learn the assemblies required to use Syncfusion&reg; SmartFormRecognizer library in various platforms and frameworks.
4+
platform: document-processing
5+
control: SmartFormRecognizer
6+
documentation: UG
7+
---
8+
9+
# Assemblies Required to work with SmartFormRecognizer
10+
The following assemblies need to be referenced in your application based on the platform.
11+
12+
<table>
13+
<thead>
14+
<tr>
15+
<th><b>Platform(s)</b></th>
16+
<th><b>Assembly</b></th>
17+
<th><b>Dependent Assemblies</b></th>
18+
</tr>
19+
</thead>
20+
21+
<!-- BASE -->
22+
<tr>
23+
<td>Windows Forms, WPF and ASP.NET MVC5</td>
24+
<td>Syncfusion.SmartFormRecognizer.Base</td>
25+
<td>
26+
<ul>
27+
<li>Syncfusion.Pdf.Base</li>
28+
<li>Syncfusion.Compression.Base</li>
29+
<li>Syncfusion.PdfToImageConverter.Base</li>
30+
</ul>
31+
</td>
32+
</tr>
33+
34+
<!-- PORTABLE -->
35+
<tr>
36+
<td rowspan="2">Blazor, .NET Core and .NET Platforms</td>
37+
<td>Syncfusion.SmartFormRecognizer.Portable</td>
38+
<td>
39+
<ul>
40+
<li>Syncfusion.Pdf.Portable</li>
41+
<li>Syncfusion.Compression.Portable</li>
42+
<li>Syncfusion.PdfToImageConverter.Portable</li>
43+
</ul>
44+
</td>
45+
</tr>
46+
47+
<!-- .NET -->
48+
<tr>
49+
<td>Syncfusion.SmartFormRecognizer.NET</td>
50+
<td>
51+
<ul>
52+
<li>Syncfusion.Pdf.NET</li>
53+
<li>Syncfusion.Compression.NET</li>
54+
<li>Syncfusion.PdfToImageConverter.NET</li>
55+
</ul>
56+
</td>
57+
</tr>
58+
</table>
59+
Lines changed: 57 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,57 @@
1+
---
2+
title: NuGet Packages for SmartFormRecognizer | Syncfusion&reg;
3+
description: Learn the NuGet packages required to use Syncfusion&reg; SmartFormRecognizer in various platforms and frameworks.
4+
platform: document-processing
5+
control: SmartFormRecognizer
6+
documentation: UG
7+
---
8+
9+
# NuGet Packages Required for SmartFormRecognizer
10+
11+
To work with SmartFormRecognizer, the following NuGet packages need to be installed in your application.
12+
13+
<table>
14+
<tr>
15+
<thead>
16+
<th><b>Platform(s)</b></th>
17+
<th><b>NuGet Package</b></th>
18+
</thead>
19+
</tr>
20+
<tr>
21+
<td>
22+
Windows Forms
23+
</td>
24+
<td>
25+
{{'[Syncfusion.SmartFormRecognizer.WinForms.nupkg]'| markdownify }}
26+
</td>
27+
</tr>
28+
<tr>
29+
<td>
30+
WPF
31+
</td>
32+
<td>
33+
{{'[Syncfusion.SmartFormRecognizer.WPF.nupkg]'| markdownify }}
34+
</td>
35+
</tr>
36+
<tr>
37+
<td rowspan="2">Blazor, .NET Core and .NET Platforms</td>
38+
<td>
39+
{{'[Syncfusion.SmartFormRecognizer.NET.nupkg]'| markdownify }}
40+
</td>
41+
</tr>
42+
<tr>
43+
<td>
44+
{{'[Syncfusion.SmartFormRecognizer.Net.Core.nupkg]'| markdownify }}
45+
</td>
46+
</tr>
47+
<tr>
48+
<td>
49+
ASP.NET MVC5
50+
</td>
51+
<td>
52+
{{'[Syncfusion.SmartFormRecognizer.AspNet.MVC5.nupkg]'| markdownify }}
53+
</td>
54+
</tr>
55+
</table>
56+
57+
N> The above mentioned NuGet packages are available in [nuget.org](https://www.nuget.org/).
Lines changed: 93 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,93 @@
1+
---
2+
title: Smart Form Recognizer | Syncfusion&reg;
3+
description: Learn how to detects form data from PDFs and scanned images using Syncfusion&reg; Essential Studio&reg; SmartFormRecognizer.
4+
platform: document-processing
5+
control: SmartFormRecognizer
6+
documentation: UG
7+
keywords: Assemblies
8+
---
9+
10+
# Smart Form Recognizer
11+
12+
Smart Form Recognizer is a deterministic, on premise C# library for .NET designed to reliably detect form data from PDFs and scanned images. Unlike AI‑based approaches, this library uses visual layout heuristics including lines, boxes, and circular markers to identify form structures with high consistency and predictability.It supports to identify the common form controls such as text fields, checkboxes, radio buttons, and signature regions, producing clean, structured JSON that can be fed directly into review and workflow systems.
13+
14+
15+
Core Capabilities
16+
17+
*Form layout detection: Locate form regions using graphical heuristics (lines, boxes, circles) for consistent field discovery.
18+
19+
*Fillable PDF export: Create a PDF with detected form fields added so documents are immediately usable in form workflows.
20+
21+
*Page-level control: Process specific pages or page ranges for targeted extraction.
22+
23+
*Multi-format support: Works with PDF, JPEG, PNG and other common image formats.
24+
25+
*Confidence filtering: Per-field confidence scores with configurable thresholds to control output quality and drive review logic.
26+
27+
*Ready for .NET integration: Deterministic, on premise library that outputs JSON and integrates into existing .NET pipelines and review UIs.
28+
29+
30+
<b>NuGet</b>
31+
32+
<table>
33+
<tr>
34+
<thead>
35+
<th><b>Platform(s)</b></th>
36+
<th><b>NuGet Package</b></th>
37+
</thead>
38+
</tr>
39+
<tr>
40+
<td>
41+
Windows Forms
42+
</td>
43+
<td>
44+
{{'[Syncfusion.SmartFormRecognizer.WinForms.nupkg]'| markdownify }}
45+
</td>
46+
</tr>
47+
<tr>
48+
<td>
49+
WPF
50+
</td>
51+
<td>
52+
{{'[Syncfusion.SmartFormRecognizer.WPF.nupkg]'| markdownify }}
53+
</td>
54+
</tr>
55+
<tr>
56+
<td rowspan="2">Blazor, .NET Core and .NET Platforms</td>
57+
<td>
58+
{{'[Syncfusion.SmartFormRecognizer.NET.nupkg]'| markdownify }}
59+
</td>
60+
</tr>
61+
<tr>
62+
<td>
63+
{{'[Syncfusion.SmartFormRecognizer.Net.Core.nupkg]'| markdownify }}
64+
</td>
65+
</tr>
66+
<tr>
67+
<td>
68+
ASP.NET MVC5
69+
</td>
70+
<td>
71+
{{'[Syncfusion.SmartFormRecognizer.AspNet.MVC5.nupkg]'| markdownify }}
72+
</td>
73+
</tr>
74+
</table>
75+
76+
N> The above mentioned NuGet packages are available in [nuget.org](https://www.nuget.org/).
77+
78+
The following code snippet illustrates how to detects form data from PDFs using FormRecognizer method in SmartFormRecognizer.
79+
80+
{% tabs %}
81+
{% highlight c# tabtitle="C#" %}
82+
83+
//Initialize the Form Recognizer
84+
FormRecognizer smartFormRecognizer = new FormRecognizer();
85+
//Read the input PDF file as stream
86+
FileStream inputStream = new FileStream("Input.pdf", FileMode.Open, FileAccess.ReadWrite);
87+
//Recognize the form and get the output as PDF stream
88+
PdfLoadedDocument pdfLoadedDocument =recognizer.RecognizeFormAsPdfDocument(inputStream);
89+
//Save the loadeddocument
90+
pdfLoadedDocument.Save(Output.pdf);
91+
92+
{% endhighlight %}
93+
{% endtabs %}

0 commit comments

Comments
 (0)