I added an editable version of the sheet editable version of the sheet. 
<https://docs.google.com/spreadsheets/d/18gZNDg19VSfqlyqRmftkrfqqRylMDm0JSfhW8eOItNI/edit?usp=sharing>
 In 
that sheet you can click "tools/script editor" and see the actual source. 
Currently the source is set to draw a simple bar graph, but you can swap 
the comments in code.gs to make it do the nonfunctional timeline chart.

To deploy the source you must make a copy of the sheet (so you are the 
owner), and press the cloud shaped deploy icon in the script editor.
 

> Hmm, there's nothing in that sheet that tells me anything - no error 
> messages, warnings, or indication that it *might* be trying to draw a 
> chart, or even that it is importing an HTML file.  Can you create another 
> sheet with a non-Timeline chart that works so I can see what it should be 
> outputting?
>
> On Thursday, August 21, 2014 10:24:55 AM UTC-4, Mackey McCandlish wrote:
>>
>> Added shared doc with just this part:
>>
>> https://docs.google.com/spreadsheets/d/1OlInCobyHdrLJbtrDZ2VltD3cLYk-EsmPRywf6c-mtg/edit?usp=sharing
>>
>> Thanks for catching the comma. It was not a problem in earlier revisions 
>> though, and it still doesn't work when I fix it. Also tried adding 
>> <!DOCTYPE html>.
>>
>> Thanks for the assistance. 
>>
>> On Wednesday, August 20, 2014 5:31:31 AM UTC-7, Andrew Gallant wrote:
>>>
>>> The only problems I see with that file are that it is missing a 
>>> <!DOCTYPE> declaration, and it has an errant comma at the end of the data 
>>> array:
>>>
>>> var data = google.visualization.arrayToDataTable([
>>>     ['Pres', 'Start', 'End'],
>>>     ['2004',  new Date(1789, 3, 29),      new Date(1797, 2, 3)],
>>>     ['2005',  new Date(1797, 2, 3),       new Date(1801, 2, 3)],
>>>     ['2006',  new Date(1801, 2, 3),       new Date(1809, 2, 3)], <-- 
>>> this comma
>>> ]);
>>>
>>> These two issues will prevent the chart from drawing in IE8 and older, 
>>> but otherwise the chart should draw fine.  Do you have a public-facing page 
>>> where this is being pulled in by the HtmlService that I can test?
>>>
>>> On Wednesday, August 20, 2014 2:24:47 AM UTC-4, Mackey McCandlish wrote:
>>>>
>>>> Here is the html, it is just an example from the visualization samples, 
>>>> wrapped in <html><body>.
>>>>
>>>> On Tuesday, August 19, 2014 4:11:40 PM UTC-7, Andrew Gallant wrote:
>>>>>
>>>>> Can you attach Timeline.html here?
>>>>>
>>>>> On Tuesday, August 19, 2014 9:49:13 AM UTC-4, Mackey McCandlish wrote:
>>>>>>
>>>>>> doGet() returns HtmlService.createHtmlOutputFromFile('timeline'), and 
>>>>>> timeline.html has the html in it. Timeline.html is another file in the 
>>>>>> project.
>>>>>>
>>>>>> Thanks.
>>>>>>
>>>>>> On Monday, August 18, 2014 5:18:09 PM UTC-7, Andrew Gallant wrote:
>>>>>>>
>>>>>>> Is the chart code in the file you load through the 
>>>>>>> HtmlService.createHtmlOutputFromFile call, or is it in apps script?
>>>>>>>
>>>>>>> On Monday, August 18, 2014 10:31:46 AM UTC-4, Mackey McCandlish 
>>>>>>> wrote:
>>>>>>>>
>>>>>>>> I've been able to create charts in javascript and display them from 
>>>>>>>> my googlescript app, by using an app that returns 
>>>>>>>> HtmlService.createHtmlOutputFromFile('filename');
>>>>>>>>
>>>>>>>> When I try to do this with a timeline chart, nothing appears. The 
>>>>>>>> script is from google's visualization example at 
>>>>>>>> https://google-developers.appspot.com/chart/interactive/docs/gallery/timeline
>>>>>>>> .
>>>>>>>>
>>>>>>>> Is this meant to be supported?
>>>>>>>>
>>>>>>>> Thanks.
>>>>>>>>
>>>>>>>

-- 
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 http://groups.google.com/group/google-visualization-api.
For more options, visit https://groups.google.com/d/optout.

Reply via email to