The style role would go after the number column.  But if you do it this
way, you won't get each item in the legend, unfortunately.

You can dynamically construct a datatable, or dataview, that has any number
of columns, however, so that should result in a single stack, with each
item in the legend as well.

On Tue, Jun 20, 2017 at 3:36 PM, Matt <[email protected]> wrote:

> Daniel,
>
> Thanks for the quick response. I'm loving google charts - they've allowed
> me to create some really cool stuff.
>
> My "clients" will be dynamic, so I can't define those. You're suggesting
> something like I have below. Is it possible to have each client in the
> legend?
>
> function drawStacked() {
>       var data = new google.visualization.DataTable();
>       data.addColumn('string', 'Week');
>       data.addColumn({type: 'string', role: 'style'});
>       data.addColumn('number', 'Hours');
>       data.addRows( {{ sbl1|safe }} );
>
> --
> 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 google-visualization-api@
> 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/d1cb1829-bfcf-497b-b864-
> 361c2bfe5fb9%40googlegroups.com
> <https://groups.google.com/d/msgid/google-visualization-api/d1cb1829-bfcf-497b-b864-361c2bfe5fb9%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
>
> For more options, visit https://groups.google.com/d/optout.
>



-- 
Daniel LaLiberte <https://plus.google.com/100631381223468223275?prsrc=2>
[email protected] <[email protected]>   5CC, Cambridge MA

-- 
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 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/CAOtcSJMM4nN5TVg9Nga_OUWMyuyvb8nvCoRfEothfmjjeVk%3Dag%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to