当我尝试在Xcode中构建我的MacOS应用程序时,我得到了一个错误。 Command MergeSwiftModule failed with a nonzero exit code.
error: umbrella for module 'PDFKit' already covers this directory
umbrella header "PDFKit.h"
^
error: inferred submodules require a module with an umbrella
我用PdfKit在Swift中有一个pdf文件的代码
但电子邮件无法打开应用程序我没有收到任何错误
let mailComposeViewController = MFMailComposeViewController()
if let lastPathComponent = pdfDocument?.documentURL?.lastPathComponent,
let documentAttributes = pdfDocument?.documentAttributes,
let attachmentData = pdfD
我安装了pdfkit,甚至还安装了wkhtmltopdf,但是每次我尝试创建pdf时都会出现以下错误。
PDFKit::NoExecutableError
No wkhtmltopdf executable found at bundler: command not found: which
Install missing gem executables with `bundle install`
>> Please install wkhtmltopdf - https://github.com/jdpace/PDFKit/wiki/Installing-WKHTMLTOPDF
当我使用下面的代码时,我得到了上面的错误。
var pdf = new PDFDocument({
autoFirstPage: false
});
pdf.fontSize(10);
var table = new PdfTable(pdf, {
bottomMargin: 30,
});
for (var l = 0; l < attendance.length; l++) {
pdf
.text("Employee Name : "+attendance[l].empl
我想将HTML文件转换为PDF
示例输入
看起来不错,可以在我的浏览器中看到内容。
代码
import pdfkit # convert html to pdf
pdfkit.from_file('income_contract_01.html', 'res.pdf')
问题
我希望看到res.pdf中的数据。但是我却看到了一个空文件:
无文本
但是相同的行数
使用的环境和版本:
python 3.9
pdfkit versiion 1.0.0
wkhtmltopdf is the newest version (0.12.2.4-1)
OS