Hi Kyle
I just tried your example and it looks like it is working as intended.
Notice that if there is no change in data the query returns with the
"not_modified" flag which prevents your handler from being called.
Otherwise, if there is a change in data, the next query will hold the new
data.
Please verify that your example code doesn't have any problems accessing the
spreadsheet you are editing.

ChartMan



On Thu, Jun 18, 2009 at 9:43 PM, kyle Hailey <[email protected]> wrote:

>
> Refresh doesn't seem to do anything for motion chart.
> Here is my code
>
> <html>
>  <head>
>      <script type="text/javascript"
> src="http://www.google.com/jsapi";></script>
>      <script type="text/javascript">
>      google.load('visualization', '1', {'packages':['motionchart']});
>      google.setOnLoadCallback(initialize);
>      function initialize() {
>        var query = new google.visualization.Query(
>           '
> http://spreadsheets.google.com/ccc?key=rvnro3rePJbLydMYqoQkVpA&hl=en');
>         query.setRefreshInterval(10);
>         query.send(draw);
>      }
>       function draw(response) {
>          if (response.isError()) {
>           alert('Error in query')
>          }
>          var ticketsData = response.getDataTable();
>          var chart = new
> google.visualization.MotionChart(document.getElementById('chart_div'));
>          chart.draw(ticketsData, {width: 450, height:450});
>      }
>    </script>
>  </head>
> <div id="chart_div" style="align: center; width: 700px; height:
> 300px;"></div>
>
> When I modify the spreadshteet I get no change in motion chart. If I
> reload the motion chart I see the new data.
> I'm not even clear what should happen in a Motion Chart with the new
> data. Where in the time line would the data be displayed?
> Ideally I would want the latest points shown.
> I would wildly guess that if refresh worked it might just put the time
> back to the beginning but the chart would contain a longer time line.
>
> Best Wishes
> Kyle Hailey
> http://sites.google.com/site/youvisualize/
> http://oraclemonitor.com
>
> >
>

--~--~---------~--~----~------------~-------~--~----~
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