Thank you Riccardo

That answers all my questions regarding serialization (to file).

I am still very confused about support of parameters as of now().

I am trying to milk as much goodness from the Areachart API that I can 
right now. So I have tried many of the configuration parameters
listed in 
http://code.google.com/apis/chart/interactive/docs/gallery/areachart.html

Most cause a failure to generate the image when used in html/js/json 
in a web page or cgi script.

Is there a resource where we are able to lookup which of the paramters 
are currenlty supported and which not? This would save me the time of 
having to test each parameter manually. Or do they all work but I am 
just doing something wrong?

Thanks a lot Riccardo.

-- 
Eric
Riccardo Govoni ☢ said:
> I think there's a bit of confusion here. What exactly do you mean by
> 'serializing' the chart ?
> 
> If you intend to persist the chart state in same format that can be later
> rebuilt, this is already available, for example using ChartWrapper.toJSON() .
> See the sources of this example which draws a chart, serializes it into a json
> string and then parses it back again to build a clone. 
> 
> If you intend converting the chart to image, then indeed that is something 
> that
> is currently explicitly supported only inside Google Apps Script via the
> getBlob() method you mentioned. Alternatives way, such as converting the chart
> svg into <canvas /> and building an image out of that, could probably work, 
> but
> they are outside the library boundary (read: you have to implement them on 
> your
> own).
> 
> -- R.
> 
> On 31 October 2011 13:16, Roni Biran <[email protected]> wrote:
> 
>     according to the I/O 2011 (London GTUG) this feature is supposed to be
>     supported in the future for ChartWrapper (http://www.battlehorse.net/
>     wontlast/gtugChartsLondon/index.html#27), however I don't think it's
>     supported at the moment.
> 
>     I know for myself, that I need this feature for exporting charts as 
> images.
>     If you'll find a way to make it work, please let us all know.
> 
> 
> 
>     On Mon, Oct 31, 2011 at 1:10 PM, Eric <[email protected]> wrote:
> 
>         I am using the html examples at
>         http://code.google.com/apis/ajax/playground/#line_chart
> 
>         This html I paste into a server page.
> 
>         How do I load the appropriate libraries and call the methods in order
>         to 
>         serialize the chart produced?  Please could someone refer me to a
>         *working example*
>         of html/javascript for this.
> 
>         I am able to implement this with the examples given for serialization
>         and email but then only as a function in a script editor.
>         I believe this has to do with my lack of understanding of the
>         javascript and the loading of libraries with google.load.
>         When I try to include the following code in an html page in the , I 
> get
>         "unexpected Identifier"
>         or "unknown method getBlob".
> 
>         First I change the line
>         new google.visualization.LineChart( ...
>         to
>         var myChart =  new google.visualization.LineChart(...
> 
>         Then in the main function of the linechart example, add the stanzas;
> 
>         var chartBlob = myChart.getBlob().getBytes();
> 
>                var chartFile = [{fileName: "chart.png",
>                                  mimeType: "image/png",
>                                   content: chartBlob}];
> 
>         I would appreciate advice on how to implement this correctly.
> 
> 
>         --
>         You received this message because you are subscribed to the Google
>         Groups "Google Visualization API" group.
>         To view this discussion on the web visit https://groups.google.com/d/
>         msg/google-visualization-api/-/-HUmK2on2vwJ.
>         To post to this group, send email to
>         [email protected].
>         To unsubscribe from this group, send email to
>         [email protected].
>         For more options, visit this group at http://groups.google.com/group/
>         google-visualization-api?hl=en.
> 
> 
>     --
>     You received this message because you are subscribed to the Google Groups
>     "Google Visualization API" group.
>     To post to this group, send email to
>     [email protected].
>     To unsubscribe from this group, send email to
>     [email protected].
>     For more options, visit this group at http://groups.google.com/group/
>     google-visualization-api?hl=en.
> 
> 
> --
> You received this message because you are subscribed to the Google Groups
> "Google Visualization API" group.
> To post to this group, send email to 
> [email protected].
> To unsubscribe from this group, send email to
> [email protected].
> For more options, visit this group at http://groups.google.com/group/
> google-visualization-api?hl=en.

-- 
You received this message because you are subscribed to the Google Groups 
"Google Visualization API" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/google-visualization-api?hl=en.

Reply via email to