Need help in GVIZ tablechart

22 views
Skip to first unread message

Vivek More

unread,
Oct 16, 2012, 2:40:11 AM10/16/12
to google-visua...@googlegroups.com
Hi

I have a application, where I am migrating simple HTML table to GVIZ table chart. In migration I am facing some issues as mentioned below

1. Can we apply  formatter (specifically color formatter) to specific cell based on some criteria in table instead of complete column.

2. Can we generate multiple header rows in gviz table chart. Like something shown in figure.


3. Can we provide multiple hyperlinks in table charts based on column contents.

Kindly let me know how can I do it or if there is any other alternatives.


Thanks,
Vivek

asgallant

unread,
Oct 16, 2012, 11:01:19 AM10/16/12
to google-visua...@googlegroups.com
To answer in order:

1) The formatters only work on columns, so you can't apply one of them to just one cell.  You can manually format the cell, though, by setting the formatted value of the cell to whatever you want via DataTable#setFormattedValue.
2) No, you can't have multiple header rows.  You can use line breaks (via the "<br />" html tag) to make a cell multi-line, but you can't add an additional header row.  Depending on the setup of your table, you might be able to use the first data row as an additional header row, but that would likely only work in very specific circumstances.
3) There are multiple ways to add links to your charts.  You may be able to use a PatternFormatter to build your links, but if not, you can manually format your data with whatever links you want in whatever way you want.
Reply all
Reply to author
Forward
0 new messages