word excel转pdf,pdf合并,插入页码

word excel转pdf,pdf合并,插入页码

将word转换为pdf,excel转换为pdf.pdf合并及在最终的pdf中添加页码

word转换为pdf

 String wordPath = "C:\\Users\\cada\\Documents\\Tencent Files\\csasd\\FileRecv\\asdasd.docx";
 if(AsposeWordUtil.isLicense()){

      Document document = new Document(wordPath);

      document.save("C:\\Users\\af\\Documents\\Tencent Files\\asd\\FileRecv\\asdasdpdf", SaveFormat.PDF);
}
       

excel转换为pdf

String cellPath = "C:\\Users\\ccc\\Documents\\Tencent Files\\cccs\\FileRecv\\1.xlsx";

if(AsposeCellsUtil.isLicense()){
     Workbook workbook = new Workbook(cellPath);

     workbook.save("C:\\Users\\ccc\\Documents\\Tencent Files\\ccc\\FileRecv\\cc.pdf", com.aspose.cells.SaveFormat.PDF);
 }

pdf合并

com.aspose.pdf.Document pdfDocument1 =
                    new com.aspose.pdf.Document("C:\\Users\\asf\\Documents\\Tencent Files\\wfda\\FileRecv\\afas.pdf");
            // Open second document
com.aspose.pdf.Document pdfDocument2 =
                    new com.aspose.pdf.Document("C:\\Users\\asww\\Documents\\Tencent Files\\asfsaaw\\FileRecv\\1.pdf");
            pdfDocument1.getPages().add(pdfDocument2.getPages());
 pdfDocument1.save("C:\\Users\\adas\\Documents\\Tencent Files\\adda\\FileRecv\\result.pdf");

添加页码

作者QQ

Γ(z)=∫0∞676621871 \Gamma(z) = \int_0^\infty 676621871 Γ(z)=0676621871

评论 1
成就一亿技术人!
拼手气红包6.0元
还能输入1000个字符
 
红包 添加红包
表情包 插入表情
 条评论被折叠 查看
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值