We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Is it possible to perform Word to PDF conversion in Azure Environment ?

Platform: ASP.NET Web Forms |
Control: DocIO

Yes, it is possible to perform Word document to PDF conversion in Azure Web sites using Essential DocIO and PDF libraries.

Step 1:

Create an Azure web site project and refer the below Word document to PDF dependent assemblies on it.

  1. Syncfusion.Compression.Base.dll
  2. Syncfusion.OfficeChart.Base.dll
  3. Syncfusion.DocIO.Base.dll
  4. Syncfusion.DocToPDFConverter.Base.dll
  5. Syncfusion.Pdf.Base.dll
  6. Syncfusion.OfficeChartToImageConverter.Wpf.dll
  7. Syncfusion.SfChart.WPF.dll

The following code example illustrates how to convert a Word document into PDF document.





Know limitation:

The metafile images (*.wmf, *.emf) in Word document are not supported while converting to PDF.


Please make use of the below sample for converting Word document into PDF in Azure environment. This sample is created targeting Azure SDK 2.6.210 and Visual studio 2015.

Sample link:


2X faster development

The ultimate ASP.NET Web Forms UI toolkit to boost your development speed.
You must log in to leave a comment
Brad Vossler
Aug 28, 2017

I have been trying to do this in Azure with the new version ( but still end up getting "A generic error occurred in GDI+" errors when the ConvertToPDF method executes. Below is my code. Am I doing something wrong?

Thank you

            Dim wordDocument As Syncfusion.DocIO.DLS.WordDocument = Nothing

            Select Case Extension.ToUpper().Trim()

                Case "DOCX", "DOTX"

                    wordDocument = New Syncfusion.DocIO.DLS.WordDocument(ms, Syncfusion.DocIO.FormatType.Docx)

                Case "DOC"

                    wordDocument = New Syncfusion.DocIO.DLS.WordDocument(ms, Syncfusion.DocIO.FormatType.Doc)

                Case "DOT"

                    wordDocument = New Syncfusion.DocIO.DLS.WordDocument(ms, Syncfusion.DocIO.FormatType.Dot)

                Case "RTF"

                    wordDocument = New Syncfusion.DocIO.DLS.WordDocument(ms, Syncfusion.DocIO.FormatType.Rtf)

                Case Else

                    wordDocument = New Syncfusion.DocIO.DLS.WordDocument(ms, Syncfusion.DocIO.FormatType.Automatic)

            End Select

            wordDocument.ChartToImageConverter = New Syncfusion.OfficeChartToImageConverter.ChartToImageConverter()

            Dim converter As New Syncfusion.DocToPDFConverter.DocToPDFConverter()

            Dim document As PdfDocument = converter.ConvertToPDF(wordDocument)

            Using ms2 As New MemoryStream


                FileData = ms2.ToArray()

            End Using


Dilli Babu Nandha Gopal [Syncfusion]
Sep 15, 2017

Hi Brad,


We have also ensured the above given KB sample in Microsoft Azure Tools for Microsoft Visual Studio 2015-v2.9.5. So, kindly upgrade to Microsoft Azure Tools for Microsoft Visual Studio 2015-v2.9.5 which will resolve the issue at your end.



Dilli babu.

Dec 05, 2017


We are in the process of moving an old ASP.net Web Forms system to Azure. An important part of this system is the need to generate and convert word documents to PDF. 

The strange thing is that it works perfectly in my Dev environment and on the current production environment but on Azure, the PDF is generated but all the images are missing. I have managed to manually add images to the PDF by setting the wordDoc.Background.Picture property but this is not a viable solution. 

Is there a reason the images are not being included? Am I missing something?
Any help would be appreciated ... Thanks

Mohanaselvam Jothi [Syncfusion]
Dec 06, 2017

Hi Gareth,

A support incident to track the status of your query has been created under your account. Please log on to our support website to check for further updates,

Please let us know if you have any other questions.

Mohanaselvam J

Please sign in to access our KB

This page will automatically be redirected to the sign-in page in 10 seconds.

Up arrow icon

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon

Live Chat Icon For mobile