From 0f688940bc8506c90c572e01d95c31d89bfcc83f Mon Sep 17 00:00:00 2001 From: ATCHAYASEKAR Date: Fri, 4 Sep 2026 13:37:04 +0530 Subject: [PATCH 1/3] Added the VB .NET code for Embed Font support and Word and Presentation to Markdown Conversions --- .../Conversions/powerpoint-to-markdown.md | 13 +++++++++++++ .../Word/Conversions/word-to-markdown-conversion.md | 13 +++++++++++++ .../Word-Library/NET/Working-with-Word-document.md | 11 +++++++++++ 3 files changed, 37 insertions(+) diff --git a/Document-Processing/PowerPoint/Conversions/powerpoint-to-markdown.md b/Document-Processing/PowerPoint/Conversions/powerpoint-to-markdown.md index 2635dd6895..27479bf81f 100644 --- a/Document-Processing/PowerPoint/Conversions/powerpoint-to-markdown.md +++ b/Document-Processing/PowerPoint/Conversions/powerpoint-to-markdown.md @@ -151,6 +151,19 @@ using (IPresentation presentation = Presentation.Open("Input.pptx")) } {% endhighlight %} +{% highlight vb.net tabtitle="VB.NET [Windows-specific]" %} +'Open an existing PowerPoint Presentation. +Using presentation As IPresentation = Presentation.Open("Input.pptx") + 'Initialize the chart-to-image converter to preserve charts as images. + presentation.ChartToImageConverter = New ChartToImageConverter() + + 'SmartArt, GroupShape, and OLE Object are preserved automatically on Windows. + + 'Save the PowerPoint Presentation as a Markdown file. + presentation.Save("Output.md") +End Using +{% endhighlight %} + {% endtabs %} You can download a complete working sample from GitHub. diff --git a/Document-Processing/Word/Conversions/word-to-markdown-conversion.md b/Document-Processing/Word/Conversions/word-to-markdown-conversion.md index bcc30ec85e..26057e78dc 100644 --- a/Document-Processing/Word/Conversions/word-to-markdown-conversion.md +++ b/Document-Processing/Word/Conversions/word-to-markdown-conversion.md @@ -695,6 +695,19 @@ using (WordDocument wordDocument = new WordDocument("Input.docx", FormatType.Doc } {% endhighlight %} +{% highlight vb.net tabtitle="VB.NET [Windows-specific]" %} +'Open an existing Word document. +Using wordDocument As WordDocument = New WordDocument("Input.docx", FormatType.Docx) + 'Initialize the chart-to-image converter to preserve charts as images. + wordDocument.ChartToImageConverter = New ChartToImageConverter() + + 'Text Box, Shape, Ink, MathML, and SmartArt are preserved automatically on Windows. + + 'Save the document as a Markdown file. + wordDocument.Save("WordtoMd.md", FormatType.Markdown) +End Using +{% endhighlight %} + {% endtabs %} You can download a complete working sample from GitHub. diff --git a/Document-Processing/Word/Word-Library/NET/Working-with-Word-document.md b/Document-Processing/Word/Word-Library/NET/Working-with-Word-document.md index 43dd5d950a..e1447c8a20 100644 --- a/Document-Processing/Word/Word-Library/NET/Working-with-Word-document.md +++ b/Document-Processing/Word/Word-Library/NET/Working-with-Word-document.md @@ -1063,6 +1063,17 @@ using (WordDocument document = new WordDocument("Input.docx", FormatType.Docx)) } {% endhighlight %} +{% highlight vb.net tabtitle="VB.NET [Windows-specific]" %} +'Load an existing Word document. +Using document As WordDocument = New WordDocument("Input.docx", FormatType.Docx) + 'Enable the flag to embed complete TrueType/OpenType fonts used in the document. + document.SaveOptions.EmbedFonts = True + 'Save the Word document. + document.Save("Output.docx", FormatType.Docx) + document.Close() +End Using +{% endhighlight %} + {% endtabs %} You can download a complete working sample from GitHub. From 4e52e0ad8295d08d5325e6d1d599e8f7592d6fa8 Mon Sep 17 00:00:00 2001 From: ATCHAYASEKAR Date: Fri, 4 Sep 2026 13:59:52 +0530 Subject: [PATCH 2/3] Changed the title --- .../PowerPoint/Conversions/powerpoint-to-markdown.md | 2 +- .../Word/Conversions/word-to-markdown-conversion.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Document-Processing/PowerPoint/Conversions/powerpoint-to-markdown.md b/Document-Processing/PowerPoint/Conversions/powerpoint-to-markdown.md index 27479bf81f..eb7015ffcc 100644 --- a/Document-Processing/PowerPoint/Conversions/powerpoint-to-markdown.md +++ b/Document-Processing/PowerPoint/Conversions/powerpoint-to-markdown.md @@ -115,7 +115,7 @@ async void Save(MemoryStream streams, string filename) You can download a complete working sample from [GitHub](https://github.com/SyncfusionExamples/PowerPoint-Examples/tree/master/PPTX-to-Markdown-Conversion/Convert-PPTX-to-Markdown). -### Preserving Charts, SmartArt, and Other Elements as Fallback Images +### Preserve Visual Elements as Images The .NET PowerPoint (Presentation) library preserves PowerPoint elements such as Chart, SmartArt, GroupShape, and OLE Object as fallback images when converting a PowerPoint presentation to a Markdown file. This ensures that content which does not have a direct Markdown equivalent is still retained in the output as an image. diff --git a/Document-Processing/Word/Conversions/word-to-markdown-conversion.md b/Document-Processing/Word/Conversions/word-to-markdown-conversion.md index 26057e78dc..caa3db3665 100644 --- a/Document-Processing/Word/Conversions/word-to-markdown-conversion.md +++ b/Document-Processing/Word/Conversions/word-to-markdown-conversion.md @@ -659,7 +659,7 @@ The following table shows the list of Word document elements supported in Word t -### Preserving Charts, Shapes, and Other Elements as Images +### Preserve Visual Elements as Images The .NET Word (DocIO) library preserves Word elements such as Chart, Text Box, Shape, Ink, MathML, SmartArt, Canvas, and GroupShape as fallback images when converting a Word document to a Markdown file. This ensures that content which does not have a direct Markdown equivalent is still retained in the output as an image. From 6c9ea689fe3ca0a1b790e8d0906b229a6d5cbfbf Mon Sep 17 00:00:00 2001 From: MathanKumarVaradhaRajaPerumal <92992128+MathanKumarVaradhaRajaPerumal@users.noreply.github.com> Date: Sat, 5 Sep 2026 01:20:34 +0530 Subject: [PATCH 3/3] Update Working-with-Word-document.md --- .../Word/Word-Library/NET/Working-with-Word-document.md | 1 + 1 file changed, 1 insertion(+) diff --git a/Document-Processing/Word/Word-Library/NET/Working-with-Word-document.md b/Document-Processing/Word/Word-Library/NET/Working-with-Word-document.md index e1447c8a20..894ca44a2a 100644 --- a/Document-Processing/Word/Word-Library/NET/Working-with-Word-document.md +++ b/Document-Processing/Word/Word-Library/NET/Working-with-Word-document.md @@ -1031,6 +1031,7 @@ You can embed the fonts used in a Word document directly into the saved file by N> Embedding font is supported on both Windows and cross-platform (ASP.NET Core, Blazor, .NET MAUI, and WinUI) environments. N> For cross-platform applications, install the [Syncfusion.DocIORenderer.Net.Core](https://www.nuget.org/packages/Syncfusion.DocIORenderer.Net.Core) NuGet package. N> Initialize the `DocIORenderer` to embed fonts in the document. +N> It is supported only for DOCX format document N> Embedding font is not supported on the UWP platform. Use the following code to embed fonts before saving the document.