Android - 如何将HTML转换为PDF? [英] Android - how to convert html to pdf?
问题描述
可能存在重复:
如何在Android SDK中创建PDF?
我的android应用程序中有一个html文件,我想将它保存为pdf格式?请让我知道如何做到这一点?
直接从另一个SO发布如何在Android应用程序中创建PDF?:
如果有人想在Android设备上生成PDF,请按照以下步骤操作:
$ bhttp://sourceforge.net/projects/itext/ (library)
< a href =http://www.vogella.de/articles/JavaPDF/article.html =nofollow noreferrer> http://www.vogella.de/articles/JavaPDF/article.html (教程)
根据用户评论来自SourceForge以及该解决方案下方的评论iText l图书馆已经发生了很大的变化。我强烈建议您采取一些建议,并敦促您通过重复答案中提供的解决方案:
Possible Duplicate:
How to create PDFs in Android SDK?
I have an html file in my android application, which I want to save in pdf format? Please let me know how to do it?
Taken directly from another SO post How to create PDFs in an Android app?:
if anyone wants to generate PDFs on Android device, here is how to do it:
http://sourceforge.net/projects/itext/ (library)
http://www.vogella.de/articles/JavaPDF/article.html (tutorial)
http://tutorials.jenkov.com/java-itext/image.html (images tutorial)
According to user comments from SourceForge and the comment below this solution, the iText library has changed quite a bit. I strongly recommend taking this advice with a grain of salt, and urge you to go through the solutions provided in the duplicate answer:
How to create PDFs in an Android app?
这篇关于Android - 如何将HTML转换为PDF?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!