We can't tell just from that snippet where you should insert code to do
another query. Generally, you want the following code structure.
<script src="...loader.js"></script>
<script>
google.charts.load(...)
google.charts.setOnLoadCallback(drawVisFunction);
function drawVisFunction () {
// Everything to fetch data and draw visualizations .
// fetch some data
// draw a charts or dashboard, via handler for fetching data
...
// fetch some different data
// draw a charts or dashboard, via handler for fetching data
...
}
</script>
You can handle events from controls, get the state of what was selected in
the control, and do whatever you want with that.
On Wed, Aug 3, 2016 at 7:22 PM, Chip Davis <[email protected]> wrote:
> I really just need them to appear on one page so I could create another
> query outside my drawVis function BUT.....I have tried I am an not
> knowledgeable enough to now where to place the script to get that to
> work. Would it go after the final close "}" (see below)? NOTE ALSO: I
> would like to be able to pass a control filter selection made in dashboard
> to chart outside of dashboard...is this doable?
>
> // Create the dashboard.
> var dashboard = new google.visualization.Dashboard(document.
> getElementById('dashboard')).
>
> bind([CompanyFilter], [RRR, EBITDAMarg, CACTrend,
> PortfolioWeightingFMV, FMVPortfolio,Description, RevSummary, EBITDASummary,
> PaybackSummary]).
> //, EBITDAMarg, CACTrend, PortfolioWeightingFMV,
> FMVPortfolio,Description
> bind([LPFilter],[LPAccounts]).
> // Draw the dashboard
> draw(view);
>
>
> });
>
> }
> </script>
>
> On Tuesday, August 2, 2016 at 11:02:09 AM UTC-5, Chip Davis wrote:
>>
>> I have a dashboard that queries from sheets.
>>
>> The response becomes my datatable.
>>
>> I have table charts inside my dashboard and I would like these tables to
>> populate based on queries of my datatable. I can not figure out how to have
>> one table (made in Chartwrapper) run a its own query. The next table would
>> have a separate query. My current workaround is to build my queries inside
>> sheets and place these in added columns in sheets. As a result....my
>> google sheet is starting to get really cluttered. I would rather have
>> these queries inside my charts (script) and keep my sheets data
>> uncluttered. How do I do this?
>>
>> thx in advance...
>>
>> Chip Davis
>>
> --
> 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/aa3bc9da-1be6-426d-99db-
> 4bbce986ffaf%40googlegroups.com
> <https://groups.google.com/d/msgid/google-visualization-api/aa3bc9da-1be6-426d-99db-4bbce986ffaf%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/CAOtcSJNu27cyrFxKSMrfHX49JefnGGpAkUnktct_8Y9nd9Q38g%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.