Each pie chart needs its own div on the page.  You can either draw them all 
in one function (good if they share a common DataTable) or draw them in 
separate functions.  If you draw in separate functions, then it is a good 
idea to create one initializing function that calls the drawing functions, 
and use that as the callback, like this:

google.load('visualization', '1', {packages:['corechart']});
google.setOnLoadCallback(drawCharts);

function drawCharts () {
    drawPie1();
    drawPie2();
    drawPie3();
}

function drawPie1 () {
    // draw the first pie chart
}

function drawPie2 () {
    // draw the second pie chart
}

function drawPie3 () {
    // draw the third pie chart
}​ 

On Wednesday, May 30, 2012 2:09:34 PM UTC-4, akm wrote:
>
> How can I create multiple pie charts on one page?  I've tried using 
> different divs, using different function names, but still just the second 
> chart shows up.

-- 
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/-/qdAI2U6VaYMJ.
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