PowerPointのJavaソリューション


PowerPointのJavaソリューションについて
2006年6月19日(Monday)20時06分作者:劉冬天気:気持ち:普通
JavaがPPTドキュメントを操作する資料を探して、このような情報を得ました.
  •  POI(hslf)のPPTサポートはまだ開発中であり、テスト版を含むバージョンはまだ発表されていない.開発中のコードはapacheのバージョン制御システムで取得できますが、使用できるかどうか分かりません.
  • 検索エンジンが最も多く調べたのはビジネスバージョン--TonicPoint Builder(http://tonicsystems.com/products/builder/)で、DEMO版を提供し、資料を記入してから2日後に返事をすると言った.
  • はjawin(http://jawinproject.sourceforge.net/)を使用しています.これはオープンソースのプロジェクトですが、JNI呼び出しOLEを利用してPowerPointを操作するのが原理です.そのため、マシンはWindowsシステムでなければならず、純粋なjavaのソリューションではなくPowerPointをインストールする必要があります.Here's the code to load and export a PowerPoint presentation (with strPowerPoint as the path to the PowerPoint presentation and strOutputDir as the path to a directory in which to dump the images):
    Ole32.CoInitialize();
    DispatchPtr app = new DispatchPtr("PowerPoint.Application");
    DispatchPtr preses = app.getObject("Presentations");
    DispatchPtr pres = (DispatchPtr) preses.invoke("open", strPowerPoint,
                                                   new Integer(0), new Integer(0),
                                                   Boolean.FALSE);
    pres.invoke("Export", strOutputDir, "PNG");
    pres.invoke("Close");
    app.invoke("Quit");			
    Ole32.CoUninitialize();
    The code was based on a Jawin example. Obviously, this would be really painful for any significant amount of COM interaction, but for a quick-and-dirty task like this, it's pretty sweet.

  • 引き続き検索中・・・TonicPoint Builderがdemo版を送って解読できるかどうか見てみましょう.もしだめなら、最後の案が最適だと思います.
     
     
     
     
     
    The application PowerPoint is presentation software and a part of Microsoft Office. Its native file format has a file extension of .ppt . This page lists Java software to read and write PPT files.
    Library/packageLicenseDescription
    Davisor Offisor
    Commercial
    Read Powerpoint (PPT) files. Can convert them to XML. 100% Java.
    POI
    Apache Software License 1.1
    Read and write Microsoft OLE 2 compound document format files. This includes MS Office files (DOC, XLS, PPT) written with Office versions that were released after 1997.
    Tonic Java PowerPoint Library
    Commercial, demo available
    Read, create and manipulate PowerPoint files. 100% Java. Also available is a free Java reader for PPT files .