Hi, what you are doing is explicitly formatting the date values in your
data table. What we are supporting in the new version is an option
(timeline.tooltipDateFormat) where you can specify the format of your dates
explicitly. Here's an example of that: http://jsfiddle.net/kmjs0dbd/

On Fri Nov 14 2014 at 12:01:14 PM <[email protected]> wrote:

> According to the release notes for the most recent release, Timeline -- Date
> format now available in tooltips.
>
> But it doesn't seem to work.
>
> I'm specifying version 1.  Is that wrong?  If so, what should the version
> be?
>
> Or am I doing something wrong in my code?
>
>
> google.setOnLoadCallback(drawChart);
>
> function drawChart() {
>   var container = document.getElementById("role_history");
>   var chart = new google.visualization.Timeline(container);
>   var dataTable = new google.visualization.DataTable();
>
>   dataTable.addColumn({ type: 'string', id: 'Role' });
>   dataTable.addColumn({ type: 'string', id: 'Office' });
>   dataTable.addColumn({ type: 'date', id: 'Start' });
>   dataTable.addColumn({ type: 'date', id: 'End' });
>
>   dataTable.addRows([
>    ["Sales Associate","Los Angeles", new Date(2014,10,13), new
> Date(2014,10,15) ],
>    ["Manager","Los Angeles", new Date(2013,10,12), new Date(2014,1,1) ]
>   ]);
>
>   var formatter_short = new google.visualization.DateFormat({formatType:
> 'short'});
>   formatter_short.format(dataTable, 2);
>   formatter_short.format(dataTable, 3);
>
>   var options = {
>     // Set the height to the number of rows (times row height) + the date
> label height
>     height: 2 * 41 + 50},
>     timeline: { singleColor: '#1E90FF' }
>   }
>   chart.draw(dataTable, options);
> }
>
>
>
>  --
> 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 [email protected].
> To post to this group, send email to
> [email protected].
> 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 [email protected].
To post to this group, send email to [email protected].
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