下载aspose.slides-15.9.0.jar包 http://pan.baidu.com/s/1jH3ZNbK

JAVA代码

 package webViewer;

 import java.io.*;
import com.aspose.slides.*; //引入aspose.slides-15.9.0.jar包 public class Ppt2Pdf {
private static InputStream license; /**
* 获取license
*
* @return
*/
public static boolean getLicense() {
boolean result = false;
try {
license = Test.class.getClassLoader().getResourceAsStream("license.xml");// license路径
License aposeLic = new License();
aposeLic.setLicense(license);
result = true;
} catch (Exception e) {
e.printStackTrace();
}
return result;
} /**
*
* @param args
*/
public static void ppt2pdf(String Address) {
// 验证License
if (!getLicense()) {
return;
} try {
// long old = System.currentTimeMillis();
File file = new File("C:/Program Files (x86)/Apache Software Foundation/Tomcat 7.0/webapps/generic/web/file/pdf1.pdf");// 输出pdf路径
Presentation pres = new Presentation(Address);//输入pdf路径
FileOutputStream fileOS = new FileOutputStream(file);
pres.save(fileOS, SaveFormat.Pdf);
fileOS.close(); // long now = System.currentTimeMillis();
// System.out.println("共耗时:" + ((now - old) / 1000.0) + "秒\n\n" + "文件保存在:" + file.getPath()); //转化过程耗时
} catch (Exception e) {
e.printStackTrace();
}
}
}

调用代码

 package webViewer;

 public class Test {
public static void main(String[] args){
Ppt2Pdf.ppt2pdf("C:/Program Files (x86)/Apache Software Foundation/Tomcat 7.0/webapps/generic/web/file/6.ppt");
}
}

即可生成pdf文档

java利用Aspose.slides.jar将本地ppt文档转化成pdf(完美破解版 无水印 无中文乱码)的更多相关文章

  1. java利用Aspose.cells.jar将本地excel文档转化成pdf(完美破解版 无水印 无中文乱码)

    下载aspose-cells-8.5.2.jar包 http://pan.baidu.com/s/1kUBzsQ7 JAVA代码 package webViewer; import java.io.* ...

  2. C# 利用Aspose.Slides.dll将本地ppt文档转化成pdf(完美破解版 无水印 无中文乱码)

    下载Aspose.Slides.dll   http://pan.baidu.com/s/1kVPjnzL 添加引用C#代码. using System; using System.Collectio ...

  3. java利用Aspose.words.jar将本地word文档转化成pdf(完美破解版 无水印 无中文乱码)

    package doc; import java.io.*; import junit.framework.Test; import com.aspose.words.*; public class ...

  4. C# 利用Aspose.Words .dll将本地word文档转化成pdf(完美破解版 无水印 无中文乱码)

    下载Aspose.Words .dll  http://pan.baidu.com/s/1c8659k 在vs2010中新建窗体应用程序,命名为 wordtopdf 添加Aspose.Words .d ...

  5. C# 利用Aspose.Cells .dll将本地excel文档转化成pdf(完美破解版 无水印 无中文乱码)

    Aspose.Cells .dll下载  http://pan.baidu.com/s/1slRENLF并引用 C#代码 using System; using System.Collections. ...

  6. Java利用aspose-words将word文档转换成pdf(破解 无水印)

    首先下载aspose-words-15.8.0-jdk16.jar包 http://pan.baidu.com/s/1nvbJwnv 引入jar包,编写Java代码 package doc; impo ...

  7. 利用Aspose.Word控件实现Word文档的操作

    Aspose系列的控件,功能都挺好,之前一直在我的Winform开发框架中用Aspose.Cell来做报表输出,可以实现多样化的报表设计及输出,由于一般输出的内容比较正规化或者多数是表格居多,所以一般 ...

  8. 黄聪:利用Aspose.Word控件实现Word文档的操作(转)

    撰写人:伍华聪  http://www.iqidi.com  Aspose系列的控件,功能都挺好,之前一直在我的Winform开发框架中用Aspose.Cell来做报表输出,可以实现多样化的报表设计及 ...

  9. Java实现在线预览Word,Excel,Ppt文档

    效果图:

随机推荐

  1. JVM内存模型和性能优化 转

    JVM内存模型和性能优化 JVM内存模型优点 内置基于内存的并发模型:      多线程机制 同步锁Synchronization 大量线程安全型库包支持 基于内存的并发机制,粒度灵活控制,灵活度高于 ...

  2. Delphi 使用CreateProcess创建进程并弹出进程PID值 (转)

    var  ExeName:PChar;  StartupInfo:TStartupInfo;  ProcessInfo:TProcessInformation;begin  FillChar(Proc ...

  3. jquery中ajax在firefox浏览器下“object XMLDocument”返回结果的解决办法

    asp.net中借助jquery的ajax处理功能,使用起来很方便.但是在firefox下获得的data报错object XMLDocument.这是因为默认的情况下把datatype用html来解析 ...

  4. rake :You have already activated rake 10.1.0

    rake aborted! You have already activated rake 10.1.0, but your Gemfile requires rake 10.0.3. Using b ...

  5. JSP中动态include和静态include的区别(简版)

    动态的include: 用法:<jsp:include page="1.jsp" flush="true" /> 特点:行为元素,可以带参数:先编译 ...

  6. Discrete.Differential.Geometry-An.Applied.Introduction(sig2013) 笔记

    The author has a course on web: http://brickisland.net/DDGSpring2016/ It has more reading assignment ...

  7. Katana

    - KAT101 - Katana has many nodes for operation, e.g. MaterialAssign, - The connections between nodes ...

  8. OAF_文件系列11_实现OAF读写Excel包JXL和POI的区别(概念)

    20150803 Created By BaoXinjian

  9. weave 建立跨节点docker网络

    weave的工作原理上与利用openvswitch建立vxlan基本一样,都是通过用三层的协议封装二层的报文来进行扩展,weave使用的是udp.weave封装了docker,在操作上为我们隐藏了很多 ...

  10. java获取当前日期等以及时区

    代码: public static void main(String[] args) throws Exception{ /* * 获取当前时间的办法 */ //这个获取从1970年..直到现在的毫秒 ...