QuestPDF License Error

Il y a 1 mois
Hello
In Nop 4.60.4 when I try to export an Order in PDF, i have this error:

Exception: QuestPDF is a modern open-source library. We identify the importance of the library in your projects and therefore want to make sure you can safely and confidently continue the development. Being a healthy and growing community is the primary goal that motivates us to pursue professionalism.

Please refer to the QuestPDF License and Pricing webpage for more details. (https://www.questpdf.com/license/)

If you are an existing QuestPDF user and for any reason cannot update, you can stay with the 2022.12.X release with the extended quality support but without any new features, improvements, or optimizations. That release will always be available under the MIT license, free for commercial usage. We are planning to sunset support for the 2022.12.X branch around Q1 2024. Until then, it will continue to receive quality and bug-fix updates.

The library does not require any license key. We trust our users, and therefore the process is simple. To disable license validation and turn off this exception, please configure an eligible license using the QuestPDF.Settings.License API, for example:

"QuestPDF.Settings.License = LicenseType.Community;"

Learn more on: https://www.questpdf.com/license/configuration.html

QuestPDF.Drawing.DocumentGenerator.ValidateLicense()


Thanks
Il y a 1 mois
I have resolve the problem. But I don't know if It is the best way.

In Nop.Web.Framework\Infrastructure\Extensions\ApplicationBuilderExtensions in UseNopPdf I have add this:

QuestPDF.Settings.License = LicenseType.Community;
Il y a 1 mois
What version of QuestPDF library are you using?
Il y a 1 mois
The nopcommerce package (4.60.4) that I downloaded had version 2023.12.0
I tried to update it to the latest version available (2023.12.6) but the error persisted.
Il y a 1 mois
Please note that QuestPDF changed its licenses recently. And that's why we do not plan to upgrade it.

nopCommerce 4.60 uses QuestPDF 2022.12.1 (not 2023.12 as you've mentioned). I presume you've updated the package to the newer version. And that's why you're getting this error.