Mandar Kamate
2016-08-25 11:26:29 UTC
Hi ,
I could show default all rows collapse nodes using above code.But the
requirement is now to collpase upto 3 levels from bottom of hierarchy. in
other words show hierarchy default as expanded to 3 levels only.I have
tried above code by giving hard coding valued for row index,but it
collapses the node vertically and not horizontally.
Any help will be greatly appreciated.?
Thanks,
Mandar
I could show default all rows collapse nodes using above code.But the
requirement is now to collpase upto 3 levels from bottom of hierarchy. in
other words show hierarchy default as expanded to 3 levels only.I have
tried above code by giving hard coding valued for row index,but it
collapses the node vertically and not horizontally.
Any help will be greatly appreciated.?
Thanks,
Mandar
Four year later...
This has saved me about three hours of works that otherwise would have
frustrated me to no end.
Thank you so much Viz Kid. All the best,
Tim
This has saved me about three hours of works that otherwise would have
frustrated me to no end.
Thank you so much Viz Kid. All the best,
Tim
http://code.google.com/apis/ajax/playground/#org_chart
// Create and draw the visualization.
var chart = new google.visualization.OrgChart(document.getElementById(
'visualization'));
chart.draw(data, {allowHtml: true, allowCollapse: true});
for (var i = 0; i < data.getNumberOfRows(); i++) {
chart.collapse(i, true);
}
Hope this helps,
Viz Kid
// Create and draw the visualization.
var chart = new google.visualization.OrgChart(document.getElementById(
'visualization'));
chart.draw(data, {allowHtml: true, allowCollapse: true});
for (var i = 0; i < data.getNumberOfRows(); i++) {
chart.collapse(i, true);
}
Hope this helps,
Viz Kid
Could I get an example of how to use the "collapse" function and where
to place it in the sequence of creating an OrgChart?
--
You received this message because you are subscribed to the Google
Groups "Google Visualization API" group.
To unsubscribe from this group, send email to
For more options, visit this group at
http://groups.google.com/group/google-visualization-api?hl=en.
to place it in the sequence of creating an OrgChart?
Hi.
I think that indeed the only way to make all the nodes collapsed is to
runI think that indeed the only way to make all the nodes collapsed is to
collapse on all the rows.
Best,
Viz Kid
GroupsBest,
Viz Kid
I looked through the documentation and scanned this discussion group
looking for syntax help, but I have not found it.
My experiments with this include calling the method
collapse('ndx','collapsed') (where ndx is an integer). However, none
of my permutations has made any difference in the tree -- all nodes
still are created fully expanded.
Can I get an example of node creation which will produce a collapsed
node?
Or do I need to create the tree, then visit each node while calling
the collapse method on each?
Thanks
--
You received this message because you are subscribed to the Google
looking for syntax help, but I have not found it.
My experiments with this include calling the method
collapse('ndx','collapsed') (where ndx is an integer). However, none
of my permutations has made any difference in the tree -- all nodes
still are created fully expanded.
Can I get an example of node creation which will produce a collapsed
node?
Or do I need to create the tree, then visit each node while calling
the collapse method on each?
Thanks
--
You received this message because you are subscribed to the Google
"Google Visualization API" group.
To post to this group, send email to
To unsubscribe from this group, send email to
.
For more options, visit this group at
http://groups.google.com/group/google-visualization-api?hl=en.
To post to this group, send email to
To unsubscribe from this group, send email to
.
For more options, visit this group at
http://groups.google.com/group/google-visualization-api?hl=en.
You received this message because you are subscribed to the Google
Groups "Google Visualization API" group.
To unsubscribe from this group, send email to
For more options, visit this group at
http://groups.google.com/group/google-visualization-api?hl=en.
--
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+***@googlegroups.com.
To post to this group, send email to google-visualization-***@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/b18add8b-4a99-4a03-a235-4604398b05e5%40googlegroups.com.
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+***@googlegroups.com.
To post to this group, send email to google-visualization-***@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/b18add8b-4a99-4a03-a235-4604398b05e5%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.