Sign in to follow this  
Guest Madhumita

Batch Export process with print option

Recommended Posts

 

The char will appear within this DIV. This text will be replaced by the chart.

 

 

 

 

var myChart1 = new FusionCharts("http://images.traderonline.com/img/tol-design/imt/fusioncharts/Column2D.swf", "myChartId1", "350", "300", "0", "1");

 

// myChart1.setDataURL("SimpleExample.xml");

 

myChart1.setDataXML("");

 

 

 

myChart1.render("chart1div");

 

 

 

 

 

The chart will appear within this DIV. This text will be replaced by the chart.

 

 

var myChart3 = new FusionCharts("http://images.traderonline.com/img/tol-design/imt/fusioncharts/Pie3D.swf", "myChartId3", "350", "300", "0", "1");

 

// myChart3.setDataURL("SimpleExample.xml");

 

myChart3.setDataXML("");

 

 

 

myChart3.render("chart3div");

 

 

 

 

FusionCharts Export Handler Component

 

 

var myExportComponent = new FusionChartsExportObject("fcBatchExporter1", "http://images.traderonline.com/img/tol-design/imt/fusioncharts/FCExporter.swf ");

 

//Add the charts to queue. The charts are referred to by their DOM Id.

 

myExportComponent.sourceCharts = ['myChartId1','myChartId3'];

 

 

 

//------ Export Component Attributes ------//

 

//Set the mode as full mode

 

myExportComponent.componentAttributes.fullMode='1';

 

//Set saving mode as both. This allows users to download individual charts/ as well as download all charts as a single file.

 

myExportComponent.componentAttributes.saveMode='batch';

 

//Show allowed export format drop-down

 

// myExportComponent.componentAttributes.showAllowedTypes = '1';

 

//Cosmetics

 

//default file name

 

myExportComponent.componentAttributes.defaultExportFileName = 'MyCharts';

 

myExportComponent.componentAttributes.showAllowedTypes='0';

 

 

 

//Width and height

 

myExportComponent.componentAttributes.width = '350';

 

myExportComponent.componentAttributes.height = '140';

 

//Message - caption of export component

 

myExportComponent.componentAttributes.showMessage = '1';

 

myExportComponent.componentAttributes.message = 'Click on button above to begin export of charts. Then save from here.';

 

//Render the exporter SWF in our DIV fcexpDiv

 

myExportComponent.Render("fcexpDiv");

 

 

 

 

Edited by Guest

Share this post


Link to post
Share on other sites

 

The char will appear within this DIV. This text will be replaced by the chart.

 

 

 

 

var myChart1 = new FusionCharts("http://images.traderonline.com/img/tol-design/imt/fusioncharts/Column2D.swf", "myChartId1", "350", "300", "0", "1");

 

// myChart1.setDataURL("SimpleExample.xml");

 

myChart1.setDataXML("");

 

 

 

myChart1.render("chart1div");

 

 

 

 

 

The chart will appear within this DIV. This text will be replaced by the chart.

 

 

var myChart3 = new FusionCharts("http://images.traderonline.com/img/tol-design/imt/fusioncharts/Pie3D.swf", "myChartId3", "350", "300", "0", "1");

 

// myChart3.setDataURL("SimpleExample.xml");

 

myChart3.setDataXML("");

 

 

 

myChart3.render("chart3div");

 

 

 

 

FusionCharts Export Handler Component

 

 

var myExportComponent = new FusionChartsExportObject("fcBatchExporter1", "http://images.traderonline.com/img/tol-design/imt/fusioncharts/FCExporter.swf ");

 

//Add the charts to queue. The charts are referred to by their DOM Id.

 

myExportComponent.sourceCharts = ['myChartId1','myChartId3'];

 

 

 

//------ Export Component Attributes ------//

 

//Set the mode as full mode

 

myExportComponent.componentAttributes.fullMode='1';

 

//Set saving mode as both. This allows users to download individual charts/ as well as download all charts as a single file.

 

myExportComponent.componentAttributes.saveMode='batch';

 

//Show allowed export format drop-down

 

// myExportComponent.componentAttributes.showAllowedTypes = '1';

 

//Cosmetics

 

//default file name

 

myExportComponent.componentAttributes.defaultExportFileName = 'MyCharts';

 

myExportComponent.componentAttributes.showAllowedTypes='0';

 

 

 

//Width and height

 

myExportComponent.componentAttributes.width = '350';

 

myExportComponent.componentAttributes.height = '140';

 

//Message - caption of export component

 

myExportComponent.componentAttributes.showMessage = '1';

 

myExportComponent.componentAttributes.message = 'Click on button above to begin export of charts. Then save from here.';

 

//Render the exporter SWF in our DIV fcexpDiv

 

myExportComponent.Render("fcexpDiv");

 

 

 

 

Share this post


Link to post
Share on other sites
Guest Madhumita

Hello Krishna,

Welcome to FusionCharts Forum. :)

Could you please use the FusionCharts native print option to print the chart?

If you right click on the chart you will get the print option.

You can also invoke the print method by an event, like a button click.

ref. - http://www.fusioncharts.com/docs/Contents/JS_print.html

The export functionality of FusionCharts is used to export the chart as images.

 

Awaiting your reply.

Share this post


Link to post
Share on other sites

hi ,

 

 

 

can any one help me on getting scroll bar (horizantal ) for FCF_Line.swf....

 

 

 

Thanks in advance...my code is as follows

 

 

 

 

 

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">

 

<HTML>

 

<HEAD>

 

<TITLE> New Document </TITLE>

 

<META NAME="Generator" CONTENT="EditPlus">

 

<META NAME="Author" CONTENT="">

 

<META NAME="Keywords" CONTENT="">

 

<META NAME="Description" CONTENT="">

 

</HEAD>

 

<script language="JavaScript" src="SWFcharts/FusionCharts.js"></script>

 

<script type="text/javascript">

 

function generateChart(){

 

var width=screen.width ;

 

var myChart = new FusionCharts("SWFcharts/FCF_Line.swf", "FusionCharts_1", "800", "500", "0", "0");

 

myChart.setDataURL("SWFcharts/funnelstacked.xml");

 

myChart.render("chartdiv");

 

}

 

</script>

 

 

 

<BODY onload="generateChart();">

 

<div id="header">

 

<a href="/ProWebClient/mainPage.html"><h3 id="service_header">Home</a></h3>

 

</div>

 

<div id="chartdiv" align="left"></div>

 

</BODY>

 

</HTML>

Edited by Guest

Share this post


Link to post
Share on other sites

hi ,

 

 

 

can any one help me on getting scroll bar (horizantal ) for FCF_Line.swf....

 

 

 

Thanks in advance...my code is as follows

 

 

 

function generateChart(){

 

var width=screen.width ;

 

var myChart = new FusionCharts("SWFcharts/FCF_Line.swf", "FusionCharts_1", "800", "500", "0", "0");

 

myChart.setDataURL("SWFcharts/funnelstacked.xml");

 

myChart.render("chartdiv");

 

}

 

 

 

 

Regards

 

Gangadhar

Share this post


Link to post
Share on other sites

Do we have a print option for Client-side Batch Export process? Because exported image will be sent back to client as download.

 

 

 

Can you please tell me one single step to create multiple charts as single chart with print option.

 

 

 

Thanks,

 

krishna

Share this post


Link to post
Share on other sites

Hi,

 

 

 

Basically I have multiple charts on a page. I want to be able to print all those charts in single chart. Batch Export process is the only one solution for this.

 

 

 

In Batch Export, we can use "Client Side Batch Export" (OR) "Server Side Batch Export".

 

 

 

1. Client Side Batch Export:

 

-----------------------------------------

 

I have written total code for generating the single image by using Batch Export Process. But it's not creating directly any image on serverside. I want to export all the images in a single step.

 

It's asking one more button for saving the image. And also no idea how we have to use "print" for one single image. please check attached code.

 

 

 

We can't use "exportAction" Attribute Name on client-side exporting for saving the image.

 

 

 

Ref URL :

 

http://www.fusioncharts.com/docs/?/ECBatchSetup.html

 

 

 

2. Server Side Batch Export:

 

----------------------------------------

 

As per Forum, I have downloaded zipfiles folders in my local mechine.But it's not working. Below is FORUM URL.

 

 

 

http://www.fusioncharts.com/forum/Topic22551-31-1.aspx?Update=1

 

 

 

Please check and let me know all solutions.

 

 

 

Thansk You.

 

 

 

 

 

Thanks,

 

Krishna

Share this post


Link to post
Share on other sites
Guest Madhumita

Hello,

When Flash movies are exported as image, a client-interaction is necessary, due to Flash security reasons. Hence, a save as button is required.

I am attaching an example Batch export application(client-side). Please refer to it and give your feedback.

ExportCharts.zip

Share this post


Link to post
Share on other sites

Thanks for your response. So my requirement is not going to be fit with client-side. So I will do server-side batch process.

 

 

 

Can you please send sample code for that?

 

 

 

1. It should create single chart from multiple charts and after it automatically saves with image .

 

2. I will use print() for that image.

Share this post


Link to post
Share on other sites
Guest Madhumita

Hello Krishna,

Thank you for your mail.

Please refer to the ExportCharts.zip attachment in the previous post.

Due to security reasons, Flash requires some interaction with the client to export it as an image. Hence, the images can not be saved automatically. The "Save as Single image" option will save all the charts as a single image file. Then you need to manually print the image. This process can not be automated.

I hope this helps you. Looking forward to your reply.

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
Sign in to follow this