Karthik87.mit

Issues Printing Multiple Charts In A Page

Recommended Posts

Hi,

 

I am facing issues while trying to print multiple fusion charts in a page.

 

I am using Mozilla browser and printManager feature. My doubts as follow,

 

1. If there are multiple charts in a page, will print manager send multiple printReadyStateChange events?

 

2. If i have 2 charts in my page, should i wait for 2 events to enable the print button?

 

3. When i try implementing it, sometimes i get 2 events and sometime i get only 1 event though both charts are ready and i can see the canvas also.

 

4. Or should i use additional FusionCharts.printManager.isReady() to check if the print manager is ready ??

 

Please advice and also send me some example codes for better understanding.

 

Karthik

Share this post


Link to post
Share on other sites

Sometimes i also notice this in Firefox 3.6.

 

Though i enable my print button after i get the printReady event, the chart still says, "Chart is being prepared for printing".

 

Does the print ready event mean its ready for printing?

Share this post


Link to post
Share on other sites
Guest Angshu

Hi,

 

Thanks for your post.

 

Please note that Print Manager takes a bit of time to prepare all the charts ready for printing. It depends on the size of the chart as well as the processing power of the client side computer. If print action is invoked while the Print Manager is not yet ready with the image, the chart does not show up in the print media.

 

More details at: http://www.fusioncha...intManager.html

Hope this helps.smile.gif

 

Share this post


Link to post
Share on other sites

Hi Angshu,

 

Thanks for the reply.

But this doesn solve my problem. I very well understand print manager takes times to prepare the chart.

But once it had sent the printready event to true, it means that it has already prepared all the charts.

I notice one more peculiar behavior. I have 2 charts in a page and the browser is firefox.

Once the charts are loaded(rendered properly), i open firebug and run the following piece of code,

 

 

FusionCharts.printManager.enabled(true);

FusionCharts.addEventListener ( "PrintReadyStateChange",

function (identifier, parameter) {

if(parameter.ready){

console.log('*******************Event Received:'+identifier.sender.id);

}

else{

console.log(parameter);

console.log(identifier.sender.id);

}

}

);

 

Actually according to the documentation i should get one event received as output. But the output in firebug was,

 

*******************Event Received:reviewsFCSourceChart_5981472636957736_6554894463651123 Object { ready=false, bypass=false}mentionsFCChart_2712135356657438*******************Event Received:reviewsFCSourceChart_5981472636957736_6554

Am wondering what make the ready to false in between.

Please reply for this as i am stuck here badly.

Thanks,

Karthik

 

 

 

Hi,

 

Thanks for your post.

 

Please note that Print Manager takes a bit of time to prepare all the charts ready for printing. It depends on the size of the chart as well as the processing power of the client side computer. If print action is invoked while the Print Manager is not yet ready with the image, the chart does not show up in the print media.

 

More details at: http://www.fusioncha...intManager.html

Hope this helps.smile.gif

 

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now