From f9ef62e3d56fcee315c6ff22615c9d0874e58e44 Mon Sep 17 00:00:00 2001 From: SF4524LogeshKumar Date: Fri, 10 Jan 2025 14:04:41 +0530 Subject: [PATCH 1/4] 379783: UG Documentation on How to Open PDF From Base64 Data --- .../pdfviewer/EJ2_ASP.MVC/open-pdf-file.md | 52 ++++++++++++++++++ .../EJ2_ASP.NETCORE/open-pdf-file.md | 53 +++++++++++++++++++ ej2-asp-core-toc.html | 2 +- ej2-asp-mvc-toc.html | 2 +- 4 files changed, 107 insertions(+), 2 deletions(-) create mode 100644 ej2-asp-core-mvc/pdfviewer/EJ2_ASP.MVC/open-pdf-file.md create mode 100644 ej2-asp-core-mvc/pdfviewer/EJ2_ASP.NETCORE/open-pdf-file.md diff --git a/ej2-asp-core-mvc/pdfviewer/EJ2_ASP.MVC/open-pdf-file.md b/ej2-asp-core-mvc/pdfviewer/EJ2_ASP.MVC/open-pdf-file.md new file mode 100644 index 0000000000..2538a21339 --- /dev/null +++ b/ej2-asp-core-mvc/pdfviewer/EJ2_ASP.MVC/open-pdf-file.md @@ -0,0 +1,52 @@ +--- +layout: post +title: Open PDF files in EJ2 ASP.NET MVC PDF Viewer | Syncfusion +description: Learn here all about Opening PDF in ASP.NET MVC PDF Viewer component of Syncfusion Essential JS 2 and more. +platform: ej2-asp-core-mvc +control: How to Open PDF From Base64 +publishingplatform: ##Platform_Name## +documentation: ug +--- + +# Opening a PDF from Base64 data in PDF Viewer +### Overview + +This guide demonstrates how to load a PDF document from a Base64 string into the Syncfusion PDF Viewer using ASP.NET MVC. This feature is useful for loading PDF data received from a client, database, or other sources where the document is encoded in Base64. + +### Opening PDF from Base64 data + +**Step 1:** Set Up the PdfViewer in Your ASP.NET MVC Project + + Follow the steps provided in the [link](https://ej2.syncfusion.com/aspnetmvc/documentation/pdfviewer/getting-started) to create a simple PDF Viewer sample. + +**Step 2:** Use the following code snippet to load PDF document using base64 string. + + +{% tabs %} +{% highlight html tabtitle="Standalone" %} + +@using Syncfusion.EJ2 +@{ + ViewBag.Title = "Home Page"; +} +
+
+ + + @Html.EJS().PdfViewer("pdfViewer").DocumentPath("https://cdn.syncfusion.com/content/pdf/pdf-succinctly.pdf").Render() +
+
+ + + +{% endhighlight %} +{% endtabs %} + +[View sample in GitHub](https://github.com/SyncfusionExamples/mvc-pdf-viewer-examples/tree/master/How%20to) diff --git a/ej2-asp-core-mvc/pdfviewer/EJ2_ASP.NETCORE/open-pdf-file.md b/ej2-asp-core-mvc/pdfviewer/EJ2_ASP.NETCORE/open-pdf-file.md new file mode 100644 index 0000000000..0608316130 --- /dev/null +++ b/ej2-asp-core-mvc/pdfviewer/EJ2_ASP.NETCORE/open-pdf-file.md @@ -0,0 +1,53 @@ +--- +layout: post +title: Open PDF files in EJ2 ASP.NET CORE PDF Viewer | Syncfusion +description: Learn here all about Opening PDF in ASP.NET CORE PDF Viewer component of Syncfusion Essential JS 2 and more. +platform: ej2-asp-core-mvc +control: PDF Viewer +publishingplatform: ##Platform_Name## +documentation: ug +--- + +# Opening a PDF from Base64 data in PDF Viewer +### Overview + +This guide demonstrates how to load a PDF document from a Base64 string into the Syncfusion PDF Viewer using ASP.NET CORE. This feature is useful for loading PDF data received from a client, database, or other sources where the document is encoded in Base64. + +### Opening PDF from Base64 data + +**Step 1:** Set Up the PdfViewer in Your ASP.NET CORE Project + +Follow the steps provided in the [link](https://ej2.syncfusion.com/aspnetcore/documentation/pdfviewer/getting-started) to create a simple PDF Viewer sample. + +**Step 2:** Use the following code snippet to load PDF document using base64 string. + + +{% tabs %} +{% highlight html tabtitle="Standalone" %} + +@page "{handler?}" +@model IndexModel +@{ + ViewData["Title"] = "Home page"; +} + +
+ + + +
+ + + +{% endhighlight %} +{% endtabs %} + +[View sample in GitHub](https://github.com/SyncfusionExamples/asp-core-pdf-viewer-examples/tree/master/How%20to) diff --git a/ej2-asp-core-toc.html b/ej2-asp-core-toc.html index 8a666abd7a..235d42f4db 100644 --- a/ej2-asp-core-toc.html +++ b/ej2-asp-core-toc.html @@ -1886,7 +1886,7 @@
  • Feature Modules
  • - Open PDF files + Open PDF files