Is it possible to use a NumberFormatter and BarFormatter at the same time
on a table whose underlying DataTable will be updated?
I am able to render a Table with both a numberformatter and barformatter
applied to the same column. That looks fine.
But when I change the values, the last formatter applied is the only one
that shows the correct values; the previous formatter shows the previous
values. I've even tried removing all formatters, applying one formatter,
forcing a redraw, then applying another formatter and again forcing a
redraw. But the first formatter's values are always unchanged while the
second formatter has the right values.
This is especially frustrating because in the initial rendering, the column
is formatted correctly by both formatters.
I feel like I've asked this before or seen a similar thread, but searching
this group didn't turn anything up.
Any ideas?
Pseudo code looks like:
// weightsTable is a DataTable
// weightsDisplay is a ChartWrapper
// numberFormatter and barFormatter are formatters
for {
weightsTable.setValue(i,2,weight);
weightsTable.setFormattedValue(i,2,null);
}
numberFormatter.format(weightsTable,2);
barFormatter.format(weightsTable,2);
weightsDisplay.draw();
The first time this code is run, everything looks great. But when the code
is called again (the table has already been rendered), I get the buggy
behavior.
I might resort to just deleting the entire table, though that's not a very
satisfying workaround...
thanks for any ideas,
--
You received this message because you are subscribed to the Google Groups
"Google Visualization API" group.
To view this discussion on the web visit
https://groups.google.com/d/msg/google-visualization-api/-/qk0o6OCfCFkJ.
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.