Noted. I'll put it in the docs when I get a chance.

Thanks for the suggestion!

Jon


On Fri, Aug 1, 2014 at 2:03 PM, WhoSoLovesUs <d...@rvt.com> wrote:

> Hi, ok I got it working ... thanks so much for sharing this :)
>
> Something like this would be handy to have in the Google Charts
> documentation somewhere, as I've seen it is a commonly asked question
>
>
> On Thursday, July 31, 2014 9:17:50 PM UTC-7, Andrew Gallant wrote:
>
>> There are many ways to include multiple charts on the same page.  The
>> thing they all share in common are that each chart has to have a unique
>> container div, so if I create 3 charts on a page, I might put them in 3
>> container divs with id's "chart1", "chart2", and "chart3".  You can
>> separate out the code for each chart into its own function, or you can
>> combine them all together, eg:
>>
>> function drawCharts () {
>>     // code to draw chart1
>>
>>     // code to draw chart2
>>
>>     // code to draw chart3
>> }
>> google.load('visualization', '1', {packages: ['corechart'], callback:
>> drawCharts});
>>
>> is functionally equivalent to:
>>
>> function drawChart1 () {
>>     // code to draw chart1
>> }
>>
>> function drawChart2 () {
>>     // code to draw chart2
>> }
>>
>> function drawChart3 () {
>>     // code to draw chart3
>> }
>>
>> function drawCharts () {
>>     drawChart1();
>>     drawChart2();
>>     drawChart3();
>> }
>> google.load('visualization', '1', {packages: ['corechart'], callback:
>> drawCharts});
>>
>> Is that what you are looking for?
>>
>> On Thursday, July 31, 2014 5:46:24 PM UTC-4, WhoSoLovesUs wrote:
>>>
>>> Hi,
>>>
>>> To someone familiar and comfortable with javascript this may seem like
>>> an easy task...
>>>
>>> But I'd like to put three charts on the same web page
>>>
>>> Is there any official documentation from Google about what to do in this
>>> case?
>>>
>>> I've looked online a fair bit; the problem is that every individual
>>> solution looks a little different to my eyes (not surprisingly)
>>>
>>> Thanks, basically I'm looking for some hand holding and explanation here
>>> :)
>>>
>>  --
> You received this message because you are subscribed to the Google Groups
> "Google Visualization API" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to google-visualization-api+unsubscr...@googlegroups.com.
> To post to this group, send email to
> google-visualization-api@googlegroups.com.
> Visit this group at
> http://groups.google.com/group/google-visualization-api.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Google Visualization API" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-visualization-api+unsubscr...@googlegroups.com.
To post to this group, send email to google-visualization-api@googlegroups.com.
Visit this group at http://groups.google.com/group/google-visualization-api.
For more options, visit https://groups.google.com/d/optout.

Reply via email to