15 February, 2008 17:29
Client Side PDF Generation Using Flash, Flex and AIR

As far as I know, it is really complicated and challenging task to generate PDF on the server side. We have recently faced this challenge on the client side. Our products - LiveArt and Pivot Table have to incorporate the PDF generation functionality. We have conducted several researches and I am glad to announce that it is easy (hurray :)) to generate PDF using Flash, Flex and AIR. It has become possible thanks to AlivePDF library. This post helped us to find it.

How powerful client side PDF generation is? Powerful enough to meet our main need at the moment – generate PDF document as the exact copy of graphic and data visualization objects which users get when they use our Flash/Flex products, like LiveArt and Pivot Table. AlivePDF library allows inserting JPEG format images into PDF document. The addImage method uses DisplayObject object (its incoming argument) to take a snapshot of it in JPEG format and insert into the PDF document.

AlivePDF library allows us to easily do the following:
  • Set layout, margins, get sizes;
  • Add and compose pages;
  • Use drawing primitives, manage color models;
  • Set fonts and text properties;
  • Add images in JPEG format;
  • etc.

Of course, there is no limit to perfection. Our dream is to be able to convert Flash vector objects into similar vector objects in PDF. It seems that we need a number of steps undertaken to make it real. But we will strive and will succeed!
 
4 comments
Saturday, 05 July 2008 22:47 by Matt visitor
It's not totally client side as you need PHP or CF to deliver the file content back to the browser. To my knowledge, there is no way to create PDF files without server assistance.
Thursday, 07 August 2008 09:19 by Cody visitor
Actually with Flash Player 10 you can do it all client side, no server side needed.
Thursday, 21 August 2008 23:13 by Anil visitor
Can you please explain how can we do at client side.
Friday, 19 December 2008 15:31 by Johnny visitor
Hello,
I was able to use alivePDF but I'm having a hard time to setup the text.
1. It doesn't read returns.
2. I can't reduce the space between line of text.
Any ideas?
Thanks

JFB

Flexmonster


See blogs for PIVOT

Project Tag Cloud

Blog Authors