Welcome Guest Search | Active Topics | Sign In | Register

Rendering PDF from Fusion Chart? Options
CHIEN
Posted: Wednesday, September 4, 2013 3:43:26 PM
Rank: Member
Groups: Member

Joined: 9/4/2013
Posts: 18
Hello EO Team

Fusion Chart is a full java script chart library that we use to generate our report.
Recently we are trying to use EO.PDF to convert those chart to PDF, but no success.

can you help us to find out why this pure java script html can't render to PDF?
here is an example

http://www.fusioncharts.com/demos/business/election-results-india-2009/view/index.html

Thank you
eo_support
Posted: Wednesday, September 4, 2013 4:47:28 PM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,195
Hi,

Please try to increase HtmlToPdf.Options.MinLoadWaitTime. For example:

Code: C#
//Wait for 2 seconds after the page loads
HtmlToPdf.Options.MinLoadWaitTime = 2000;

//Convert the Url
HtmlToPdf.ConvertUrl(url, pdfFileName);


The extra waiting time is necessary because the page initially load very fast and then use JavaScript to generates the map, which takes time ---- while it's easy for human to see when the map has finished loading, the converter does not know when it has finished loading. So it can start converting before the map has been fully loaded. When that occurs, you will see the page converted without map.

If the map library that you use can notify you when the map has finished loading, you can use the manual trigger feature of the EO.Pdf library to trigger the conversion only when the map finishes loading. You can find more information about trigger at here:

http://www.essentialobjects.com/doc/4/htmltopdf/eo_js.aspx

Hope this helps. Please feel free to let us know if you still have any questions.

Thanks!
CHIEN
Posted: Wednesday, September 4, 2013 7:20:15 PM
Rank: Member
Groups: Member

Joined: 9/4/2013
Posts: 18
It's amazing ... Set HtmlToPdf.Options.MinLoadWaitTime really working!!!

Thank you very much.

eo_support
Posted: Wednesday, September 4, 2013 7:29:59 PM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,195
You are very welcome. Please feel free to let us know if you have any other questions.

Thanks!


You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.