Language: ChineseGermanSpanishFrenchDutchItalianRussian
123 Flash Chat Forums

Go Back   TOPCMM Community > SWFKit > SWFKit Support

Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 06-26-2007, 01:27 PM
Junior Member
 
Join Date: Jun 2005
Posts: 22
Default Create PDF : your advice

Hi all,

I am working on creating a .pdf (with dynamic data from access) without serverside scripting.
So far i have found two methods for doing this:

* with the Blaze PDF component (http://www.blazepdf.com/index.html)
This converts to pdf inside Flash. It works: bit it's very slow and has some problems
with multiple images. It sends the PDF data to swfkit and from there it's saved.

* with pdf-printer software, e.g. Bullzip PDF (http://www.bullzip.com/products/pdf/info.php)
It works, but requires two extra installations and extra user input, which makes it not very user-friendly.

Now my question: Is there another method? What would you guys advice?
Would it be possible to bypass Flash and do it straight from swfkit?
Maybe someone knows better virtual printer scripts?

Thanks in advance

Reply With Quote
  #2 (permalink)  
Old 06-26-2007, 01:37 PM
Senior Member
 
Join Date: Dec 2002
Posts: 2,015
Default Re:Create PDF : your advice

http://www.i-logic.com/PDFActiveX.htm
Reply With Quote
  #3 (permalink)  
Old 06-26-2007, 01:52 PM
Junior Member
 
Join Date: Jun 2005
Posts: 22
Default Re:Create PDF : your advice


Thanks, that looks promising.
Would you be so kind to put me in the right direction on how to use this?
Reply With Quote
  #4 (permalink)  
Old 06-26-2007, 02:21 PM
Senior Member
 
Join Date: Dec 2002
Posts: 2,015
Default Re:Create PDF : your advice

We will make a sample for you tomorrow.
Reply With Quote
  #5 (permalink)  
Old 06-26-2007, 02:25 PM
Junior Member
 
Join Date: Jun 2005
Posts: 22
Default Re:Create PDF : your advice


Thanks, your support is greatly appreciated!
Reply With Quote
  #6 (permalink)  
Old 06-27-2007, 04:14 AM
Senior Member
 
Join Date: Dec 2002
Posts: 2,015
Default Re:Create PDF : your advice

The attached sample is translated from the asp sample on http://www.i-logic.com/PDFActiveX.htm
Reply With Quote
  #7 (permalink)  
Old 06-27-2007, 08:06 AM
Junior Member
 
Join Date: Jun 2005
Posts: 22
Default Re:Create PDF : your advice


Oh man, i am so happy with this!
Thanks again, you made my day.

This not only works much faster then the blaze-component but it also
is much easier to implement!

Maybe it's an idea to add this sample to your samples page?
Reply With Quote
  #8 (permalink)  
Old 07-20-2007, 06:54 PM
Junior Member
 
Join Date: Jun 2005
Posts: 22
Default Re:Create PDF : your advice

So far it works really well, but stumbled into a problem.

ax.textleading(page)=20;
This code doesn't seem to work, according to the maker it should work.

Could this be due to SWFkit somehow?
Reply With Quote
  #9 (permalink)  
Old 07-21-2007, 09:22 AM
Senior Member
 
Join Date: Dec 2002
Posts: 2,015
Default Re:Create PDF : your advice

SWKit cannot set value of a property that has parameters. That is, the syntax like
Code:
ax.textleading(page) = 20;
does not work. You can only get value of the property by using the following code
Code:
var value = ax.textleading(page);
We have fixed this problem by adding a new method for the ActiveXObject, which is "setProperty":
Code:
ax.setProperty("textleading", page, 20);
This method can be used to set value of any property that has parameters.

To get this method, please download the following patch, extract it intoto the "data" sub folder of the directory in which swfkit pro has been installed, for example, "c:\program files\swfkit pro 3\data", and overwrite the old file.
http://www.swfkit.com/download/swfkit/propatch.zip

To test the method, you will have to run the output exe file, as the patch is not for the preview mode.
Reply With Quote
  #10 (permalink)  
Old 07-23-2007, 09:18 AM
Junior Member
 
Join Date: Jun 2005
Posts: 22
Default Re:Create PDF : your advice

Another great fix from you! Thank you very much, it now works like a dream.
Many Flash devs fall off their chair when i show them i can generate a .pdf without
any server-side language...

A while ago you wrote a piece of code to save an xml file as utf-8.
(http://www.swfkit.com/forum/thread_1_1937.html)

I've tried to implement this for .pdf as well, but that doesn't seem to work.
Do you have any ideas on this too?
Reply With Quote
Reply

Was this information helpful?    Yes No



Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT. The time now is 04:22 AM.


Powered by vBulletin® Version 3.7.1
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.1.0 ©2007, Crawlability, Inc.