问题描述
我正在尝试使用itext7.pdfhtml将html字符串转换为C#.Net项目中的pdf文档。
当我运行此代码时:
I'm trying to use itext7.pdfhtml to convert a html string to a pdf document in a C# .Net project.When I run this code:
iText.Html2pdf.HtmlConverter.ConvertToPdf(htmlString, pdfStream)
我收到以下异常: iText.License.LicenseKeyException:未加载产品的许可证文件 。
我不想加载试用许可证或商业许可证。我想在AGPL模式下运行itext7。我该怎么做?
I don't want to load a trial license or a commercial license. I want to run itext7 in AGPL mode. How do I do that?
我正在使用:
- itext7 v7 .0.3
- itext7.licensekey v2.0.4
- itext7.pdfhtml v1.0.0.2
推荐答案
Please note that this answer is only valid for pdfHTML version 1.0.0, which is the only version released so far. At this moment there is no publicly available information if or when there will be an AGPL version of pdfHTML.
UPDATE
pdfHTML 1.0.1,计划于2017年7月底发布,也不会在AGPL版本中提供。
pdfHTML 1.0.1, scheduled for release end of July 2017, will also not be available in an AGPL version.
更新
我们目前正处于为开源制作pdfHTML的最后阶段。它应该出现在下周的GitHub和Maven Central上,并且在NuGet上用于.NET端口后不久。
We are currently in the last stages of making pdfHTML ready for Open Source. It should appear on GitHub and Maven Central somewhere next week, and not long after on NuGet for the .NET port.
UPDATE
pdfHTML 2.0.1,与iText 7.1.1和Licensekey 3.0.1兼容,绝对可以作为双重许可AGPL / Commercial提供。
pdfHTML 2.0.1, compatible with iText 7.1.1 and Licensekey 3.0.1, is most definitely available as dual license AGPL/Commercial.
这篇关于如何在AGPL模式下使用itext7.pdfhtml?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!