Convert HTML to PDF side-by-side configuration is incorrect in Azure website

Hi folks. I am using the HTML to PDF document conversion function and it works perfectly on my development machine, but when I publish my application to Azure and try to use the same function, I get the following error:

The application has failed to start because its side-by-side configuration is incorrect

The error occurs on the following line:
PdfDocument document = htmlConverter.Convert(reportURL);

Everything else on the deployed app works fine. I just get the error when the code executes the line above.
Any help or suggestions are appreciated. Thank you.


1 Reply

AM Arumugam Muppidathi Syncfusion Team November 20, 2024 01:31 PM UTC

Hi John,


The Blink rendering engine does not support conversion in the Azure app service or Azure functions in Windows due to the GDI limitations and restrictions of the Azure App service environment. So, we could not convert HTML to PDF using Blink in Azure App Service windows. So, you can use the Blink rendering engine with .NET Core library in Azure App Service Linux or Linux Docker image or  Azure Functions Linux.

Please find the below UG and KB links for more details,

Blink conversion failed in Azure app service (Windows),

Azure App Service (Linux),

Azure Functions (Linux),

Azure App Service (Linux Docker),

How to convert HTML to PDF in Azure App service Linux with Blink rendering engine? | Syncfusion,

 

If you want to use the HTML to PDF conversion in Azure App service windows,  you can use the CEF rendering engine for conversion. We have ensured the conversion using the direct visual studio approach. Please refer to the below documentation.

Convert-html-to-pdf-in-azure-app-service-windows

 

However, we have attached the sample below for your reference

Sample: HTML-to-PDF-AzureAppServiceWindows-CEF214935483

Please try the above sample and let us know the result.  Kindly get back to us if you need any further assistance.


Regards,

Arumugam M



Loader.
Up arrow icon