Gantt Chart Clickable Event

1,214 views
Skip to first unread message

Domonic Hanson

unread,
Apr 6, 2016, 10:07:07 AM4/6/16
to Google Visualization API
Hi,

I am just wondering if it is possible for the user to click on one of the items on a gantt chart it will go to a new page pulling more information about that specific project.

So for example if the user was to click on the blue bar (See below):


This would then redirect them to a page showing the stuff in the tooltip but also more data that is stored in the array.


I have searched the internet and just can't seem to find anything that offers this.


I have put this in:


function selectHandler() {
var row = data.getValue(0, 0);
alert('You selected ' + row);
}
google.visualization.events.addListener(chart, 'select', selectHandler);



I know this shows an alert but because the parameters are hard selected no matter which one you click on it shows "spring2014"

Thanks in advanced.

Daniel LaLiberte

unread,
Apr 6, 2016, 10:22:53 AM4/6/16
to Google Visualization API

--
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-visualizati...@googlegroups.com.
To post to this group, send email to google-visua...@googlegroups.com.
Visit this group at https://groups.google.com/group/google-visualization-api.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-visualization-api/fa55f3f8-57fa-4a5d-a0bc-24fc89554755%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.



--

Domonic Hanson

unread,
Apr 6, 2016, 10:31:39 AM4/6/16
to Google Visualization API
I have tried using this but it returns nothing?

function selectHandler() {
var selection = chart.getSelection();
alert('You selected ' + selection);
}
google.visualization.events.addListener(chart, 'select', selectHandler);   



On Wednesday, April 6, 2016 at 3:22:53 PM UTC+1, Daniel LaLiberte wrote:
On Wed, Apr 6, 2016 at 10:07 AM, Domonic Hanson <domjd...@gmail.com> wrote:
Hi,

I am just wondering if it is possible for the user to click on one of the items on a gantt chart it will go to a new page pulling more information about that specific project.

So for example if the user was to click on the blue bar (See below):


This would then redirect them to a page showing the stuff in the tooltip but also more data that is stored in the array.


I have searched the internet and just can't seem to find anything that offers this.


I have put this in:


function selectHandler() {
var row = data.getValue(0, 0);
alert('You selected ' + row);
}
google.visualization.events.addListener(chart, 'select', selectHandler);



I know this shows an alert but because the parameters are hard selected no matter which one you click on it shows "spring2014"

Thanks in advanced.

--
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+unsub...@googlegroups.com.



--

Daniel LaLiberte

unread,
Apr 6, 2016, 11:04:43 AM4/6/16
to Google Visualization API
The getSelection() method does return an array of selection objects, but unfortunately, the objects are empty.  See this example:  https://jsfiddle.net/hrtgp54r/

This is a bug, which I invite you to post on the issues list: https://github.com/google/google-visualization-issues

Thanks.


To unsubscribe from this group and stop receiving emails from it, send an email to google-visualizati...@googlegroups.com.



--

--
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-visualizati...@googlegroups.com.

To post to this group, send email to google-visua...@googlegroups.com.
Visit this group at https://groups.google.com/group/google-visualization-api.

For more options, visit https://groups.google.com/d/optout.



--

Di Zhang

unread,
Jun 9, 2016, 7:03:32 PM6/9/16
to Google Visualization API
Hi Daniel,

I was wondering do we have any update on this? We are also hitting this problem.

Thanks,
Di
To unsubscribe from this group and stop receiving emails from it, send an email to google-visualization-api+unsub...@googlegroups.com.



--

--
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+unsub...@googlegroups.com.

To post to this group, send email to google-visua...@googlegroups.com.
Visit this group at https://groups.google.com/group/google-visualization-api.



--

Daniel LaLiberte

unread,
Jun 10, 2016, 9:30:10 AM6/10/16
to Google Visualization API
Sorry, I've had no time for fixing this.

To unsubscribe from this group and stop receiving emails from it, send an email to google-visualizati...@googlegroups.com.



--

--
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-visualizati...@googlegroups.com.

To post to this group, send email to google-visua...@googlegroups.com.
Visit this group at https://groups.google.com/group/google-visualization-api.



--

--
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-visualizati...@googlegroups.com.

To post to this group, send email to google-visua...@googlegroups.com.
Visit this group at https://groups.google.com/group/google-visualization-api.

For more options, visit https://groups.google.com/d/optout.



--

Adam Ginsburg

unread,
Nov 25, 2016, 2:18:47 PM11/25/16
to Google Visualization API
Hi wondering if any update on this pls?
Also wondering if you could use a tooltip action to get around this? https://developers.google.com/chart/interactive/docs/customizing_tooltip_content
To unsubscribe from this group and stop receiving emails from it, send an email to google-visualization-api+unsub...@googlegroups.com.



--

--
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+unsub...@googlegroups.com.

To post to this group, send email to google-visua...@googlegroups.com.
Visit this group at https://groups.google.com/group/google-visualization-api.



--

--
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+unsub...@googlegroups.com.

To post to this group, send email to google-visua...@googlegroups.com.
Visit this group at https://groups.google.com/group/google-visualization-api.



--

Simon de Jager

unread,
Dec 5, 2016, 6:46:25 AM12/5/16
to Google Visualization API
Hi Daniel,

We are also running into this problem,
do you have an update on this issue?

Kind regards,
Simon
To unsubscribe from this group and stop receiving emails from it, send an email to google-visualization-api+unsub...@googlegroups.com.



--

--
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+unsub...@googlegroups.com.

To post to this group, send email to google-visua...@googlegroups.com.
Visit this group at https://groups.google.com/group/google-visualization-api.



--

--
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+unsub...@googlegroups.com.

To post to this group, send email to google-visua...@googlegroups.com.
Visit this group at https://groups.google.com/group/google-visualization-api.



--

Daniel LaLiberte

unread,
Dec 5, 2016, 10:04:53 AM12/5/16
to Google Visualization API
I was able to fix this problem with the lack of a row index in the selection objects for Gantt.  This fix will show up very soon.

To unsubscribe from this group and stop receiving emails from it, send an email to google-visualization-api+unsubscr...@googlegroups.com.



--

--
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-visua...@googlegroups.com.
Visit this group at https://groups.google.com/group/google-visualization-api.



--

--
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-visua...@googlegroups.com.
Visit this group at https://groups.google.com/group/google-visualization-api.



--

--
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+unsub...@googlegroups.com.
To post to this group, send email to google-visualization-api@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.



--

Daniel LaLiberte

unread,
Dec 5, 2016, 1:57:33 PM12/5/16
to Google Visualization API
You can use this fix in the 'upcoming' version now:  https://jsfiddle.net/dlaliberte/hrtgp54r/4/

--

Paulo Hernandez

unread,
Apr 26, 2018, 11:46:17 AM4/26/18
to Google Visualization API
Hello,
This fix is not present in "www.google.com/jsapi":
google.load("visualization", "1.1","packages:[corechart,gantt]");

How can I get the solution in jsapi?
To unsubscribe from this group and stop receiving emails from it, send an email to google-visualization-api+unsub...@googlegroups.com.



--

--
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+unsub...@googlegroups.com.

To post to this group, send email to google-visua...@googlegroups.com.
Visit this group at https://groups.google.com/group/google-visualization-api.



--

--
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+unsub...@googlegroups.com.

To post to this group, send email to google-visua...@googlegroups.com.
Visit this group at https://groups.google.com/group/google-visualization-api.



--

--
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+unsub...@googlegroups.com.

To post to this group, send email to google-visua...@googlegroups.com.
Visit this group at https://groups.google.com/group/google-visualization-api.



--

Daniel LaLiberte

unread,
Apr 26, 2018, 12:30:18 PM4/26/18
to Google Visualization API
The version available via the jsapi loader will not be further updated (partly because the jsapi server itself is deprecated), and you should switch to the newer versions available with the www.gstatic.com/charts/loader.js.   https://developers.google.com/chart/interactive/docs/basic_load_libs#update-library-loader-code

To unsubscribe from this group and stop receiving emails from it, send an email to google-visualizati...@googlegroups.com.



--

--
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-visualizati...@googlegroups.com.

To post to this group, send email to google-visua...@googlegroups.com.
Visit this group at https://groups.google.com/group/google-visualization-api.



--

--
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-visualizati...@googlegroups.com.

To post to this group, send email to google-visua...@googlegroups.com.
Visit this group at https://groups.google.com/group/google-visualization-api.



--

--
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-visualizati...@googlegroups.com.

To post to this group, send email to google-visua...@googlegroups.com.
Visit this group at https://groups.google.com/group/google-visualization-api.
--



--

--
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-visualizati...@googlegroups.com.

To post to this group, send email to google-visua...@googlegroups.com.
Visit this group at https://groups.google.com/group/google-visualization-api.

For more options, visit https://groups.google.com/d/optout.


--

Paulo Hernandez

unread,
Apr 26, 2018, 1:56:38 PM4/26/18
to Google Visualization API
ok thanks for your response
To unsubscribe from this group and stop receiving emails from it, send an email to google-visualization-api+unsub...@googlegroups.com.



--

--
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+unsub...@googlegroups.com.

To post to this group, send email to google-visua...@googlegroups.com.
Visit this group at https://groups.google.com/group/google-visualization-api.



--

--
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+unsub...@googlegroups.com.

To post to this group, send email to google-visua...@googlegroups.com.
Visit this group at https://groups.google.com/group/google-visualization-api.



--

--
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+unsub...@googlegroups.com.

To post to this group, send email to google-visua...@googlegroups.com.
Visit this group at https://groups.google.com/group/google-visualization-api.
--



--

--
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+unsub...@googlegroups.com.


--
Reply all
Reply to author
Forward
0 new messages