We are providing a thumbnail & preview functionality for rich powerpoint documents on our Java based site.
Currently, we are using iSpringConverter tool for converting the powerpoint documents to swf file.
The tool is licensed and windows based, and allows interaction through java.
This swf file is then launched on the client side as popups.
Can anyone suggest any other tools/frameworks/options/approaches used for implementing
- Generation of thumbnails and preview for powerpoints
- Viewers used, in case the preview is generated in some formats.
Any more ideas/suggestions.
Try SWFTOOLS, it works very well :)
You can make calls to it running command lines (using Process class).
I dont know if it transparently make thumbnails and etc... but I think you can done it by yourself using it.
hope it helps.
http://www.swftools.org/
You may try Aspose.Slides for Java to create thumbnails of the PowerPoint slides in your Java application. You can then show those images as a preview using any image control. This component doesn't require MS Office/Open Office etc. to be installed on your development or deployment machines for processing PowerPoint files. The API is quite simple and provides detailed documentation and help. Please see if this might help in your scenario.
Disclosure: I work as a developer evangelist at Aspose.
Related
In my application the user can configure their own table layouts to display the data on the screen, by choosing which colums in which order are to be shown. Now I want to give my users the possibility to export these tables to PDF. The tables should fill the page width completely and the columns should adjust their size depending on the content in the table, like e.g. HTML tables do.
Can you recomment a library or toolchain for this?
I checked Apache FOP, but their fo:tables do not support automatic table layout. Creating a Jasper Report dynamically also doesn't seem to fit, because I have to specify the exact column width there. So, does anyone have an idea how to achive this?
Open Source solutions with commercially friendly licenses like Apache or LGPL preferred.
ANSWER: There are no current tools that allow what I hoped for, so I mark this question as resolved.
iText is probably what you are looking for http://itextpdf.com/. Version 2.1.7 is free to use under the GPL lisence, for more info see this question What is latest version of itext that is not AGPL?. It will work for you need, I would recommend using their code samples on their web page. Most are applicable to version 2.1.7 although it is currently on version 5.
I would recommend you take a look at Flying Saucer. It is an open source project that uses iText PDF as its core rendering engine but it allows you to define very dynamic xhtml files as your rendering medium.
Benefits of using FS+iText using iText by itself
Allows for a much faster dev cycle for changes or new products
Very easy to add in consistent and complex styles using a language built exactly for it (HTML + CSS)
You can use the same HTML code to render your PDF as you use to view it online (if using web application)
Can render graphics using java.awt.Graphics class onto the PDF, meaning you can integrate any graphics library with FS to paint objects like graphs onto your PDF.
Downsides:
While it does a good job at rendering modern css styles it is not perfect. For instance when I used it the project required the border-radius style to be usable. It wasnt so I had to implement it.
Rendering times and memory consumption are increased (Although I have found it to be quite fast and memory efficient)
More libraires in your project.
Heres an example from the FS website if your ineterested.
https://github.com/flyingsaucerproject/flyingsaucer/blob/master/flying-saucer-examples/src/main/java/PDFRender.java
I want to generate interactive charts in PDF just like Google charts
but this is for embedding on web page I want to embed interactive chart in PDF. any help?
You specified Java, so I would say iText has some partial support for writing adobe-javascript actions. You must be aware that latest versions of itext uses AGPL license, so you must pay a commercial license if you want to use this in a commercial closed-source application.
Another option is to use Adobe Acrobat SDK, but I am not sure if you will be able to use it from Java.
You may also find this link useful: Acrobat JavaScript Scripting Guide - Adobe
This feature of the PDF specification (I mean embedded javascript) is not commonly used, so it might be a bit difficult to find start-up information and sample code.
Here you will find a few examples of interactive PDFs that use javascript, there is even an example of a flying helicopter in 3D, (it actually moves around while viewing the file).
How can we create report in Java? Something like Crystal Reports in .net.
We have Jasper Report.
JasperReports is the world's most popular open source reporting engine. It is entirely written in Java and it is able to use data coming from any kind of data source and produce pixel-perfect documents that can be viewed, printed or exported in a variety of document formats including HTML, PDF, Excel, OpenOffice and Word.
Here is quick tutorial
Might be a duplicate of this question, BTW...
Anyways, here's my honest (yet biased) answer copied from there:
i-net Clear Reports (used to be i-net Crystal-Clear)
Simple and easy-to-use API of both the report engine and the Java report viewer.
Can export into any major format like PDF, HTML, SVG, XLS, etc., as well as into a Java applet viewer. (See samples)
Comes with a free and powerful graphical report template designer. (See video guide)
Installs as a WAR file on your application server or can be used as a library within your own application.
Great technical support (you usually get an answer in minutes or hours rather than days or weeks)
Charts based on JFreeChart (so includes Stock charts).
Can read Crystal Reports templates. (for a lot of customers, this is the killer feature since you don't have to re-create all your old Crystal Reports templates)
Great and competitive pricing - effectively costing "less than open source".
Free 90-day trial of the server component.
Free and fully functional report designer.
[full disclosure: Yes, I work for i-net software. But it's still my honest (though subjective and biased) answer to the question. ;)]
Try iRepor/JasperReports. I think is your best option as of today.
It's pretty mature, constantly updated (active), it supports StandAlone/Swing Applications, Web Applications, you can export to Excel/PDF, and integrates easily with major Appilcation Servers.
JasperReports is the Reporting Engine, and iReport is its IDE (Visual Report Editor).
BIRT is a very popular and powerful tool. Recommended.
Jasper report is indeed a powerfull tool, but sometimes to much work to create a report.
I would recommend to look also to POI and Docx4j. With those you can include a template with headers and entreprise style. You can build the file with simple statements but with Docx4j you can also replace tags (templating) in your .docx file by a element of choosing.
The docx4j(ava) documentation is available here: https://www.docx4java.org/forums/
By "not depend on automation", I mean that it should not require a Microsoft Office installation to work; let alone interact with a live instance of a Microsoft Office component. One such library is Aspose.Total for Java. Are there any more out there?
Another solution I'm considering is to use OpenOffice.org. However, I'm not sure if I'm going to run into the same problems as with Microsoft Office as detailed here.
For Office Documents: http://poi.apache.org/
I have not tried this myself, but Apache usually deliver good libraries
For just Excel: JExcel API for Java
I use this for one application, and it works quite well. May use a fair bit of RAM for larger documents.
One designed specifically to with with the newer XML formats is docx4j: http://dev.plutext.org/trac/docx4j
There are two further answers for this question. Depending on your application.
can borrow from the OpenOffice library code that deals with opening and saving MS Office files. (See: http://www.artofsolving.com/opensource/jodconverter or jOpenDocument )
You might just use OpenOffice itself by scripting or automating that.
I faced this question a while back with a Ruby app and because I was in control of the source document, I got the originator to save things as HTML format and used Tidy to filter the junk. Another option it to find a tool to convert the Office files to RTF which is more generic.
Another to consider ...
LibreOffice looks useful.
jExcelAPI if you just want excel.
Finally there are some opportunities on sourceForge, try this search: http://sourceforge.net/search/?q=java+ms+office
You may find spreadsheets BIG unless you use OpenOffice or MS Office because you need to have a fancy shamancy virtual sparse matrix to do what they do well.
ODF Toolkit - http://odftoolkit.org
Can anyone tell me how to create doc files using java?
I know, there's a POI library, but it seems like it can save only simple documents. You can read anything you wish, but you can't save it all back again. Or may be i missed something? How can i save whole document with pictures, tables and styles?
Docmosis lets you do heaps of styling easily via the template. Uses OpenOffice and Java to do the job. Its free and free to distribute.
It ain't cheap, but you could try Aspose.Words. It'll do everything you state above and more.
JODConverter will allow you to convert lots of different document formats
OpenOffice.org's Universal Network Objects (UNO), allow you to generate .doc,.PDF, as well as OpenOffice documents. It supports several programming languages like: Java, C++, Visual Basic, etcc..
Some good things is that: its free, open source and plataform-independent
You can build documents, spreadsheets, presentations, etc. Start from scratch or using a template and fill the gaps..
In order to use it you will need to include some libraries that comes with the OpenOffice suite.
Useful links:
Open Office home
Open Office UNO Developer's Guide