English 中文(简体)
进入谷歌视觉化反应
原标题:Accessing response status in Google Visualization API

在下文的《德米法》中,从谷歌转录的样本中一般说来,有三项功能——二项是“要求”的,另一项是“赖斯”的。 如果电子表格申请无效,我可以查阅从处理QueryResponse()职能中收回的错误信息。 但为了我的目的,我需要能够测试反应的存在。 a 系从Me(Me)运行功能中提取。 这似乎很简单,但我似乎无法从处理QueryResponse()之外的回复对象那里得到。 这可能是由于我的 Java新古贝状况,或者因为安普森做了一些犹豫。

我也认为,令人感到奇怪的是,不相干的 con(频率);在可采的Meta(频率)功能中,会产生一种“Er”物体,似乎只是一种原型,而不是代表实际的质。

感谢建议。

下面的电子表格在“z”最终失效,并在删除后有效。

function runMe() {
    var foo = getTableMeta( 0AtP_YtDJ532RdDcxZUl6Zkl4YkxKcEYzbld4ZDA4SlEz );
    // console.log(response);
    // console.log(response.getMessage());
    // console.log(foo.getMessage());
}  


// Get table metadata from Google
function getTableMeta(spreadsheet_id) {

    var query = new google.visualization.Query( https://spreadsheets.google.com/a/google.com/tq?key=  + spreadsheet_id);
    // console.log(query);
    query.send(handleQueryResponse); 
    }       


function handleQueryResponse(response) {
    if (response.isError()) {
        // alert( Error in query:   + response.getMessage() +     + response.getDetailedMessage() +  . Please click Previous and enter a different spreadsheet ID. );
        console.log(response.getMessage());
    }    
    return response;
}   

runMe();  

http://code.google.com/apis/chart/interactive/docs/ reference.html>rel=“nofollow> 附件二

最佳回答

不幸的是,你获得<条码>.runMe()功能的价值。 这是因为它发出的呼吁是同步的;它只是发出一项请求,其答复将由特定的反馈职能处理,就你的情况而言,handleQueryResponse

我会看一看一看。 只是一个触发因素;无论你希望列入这一职能的任何逻辑,都侧重于在<条码>上开展工作。

Hope that helps. Feel free to provide more context if I ve misinterpreted something.

问题回答

暂无回答




相关问题
selected text in iframe

How to get a selected text inside a iframe. I my page i m having a iframe which is editable true. So how can i get the selected text in that iframe.

How to fire event handlers on the link using javascript

I would like to click a link in my page using javascript. I would like to Fire event handlers on the link without navigating. How can this be done? This has to work both in firefox and Internet ...

How to Add script codes before the </body> tag ASP.NET

Heres the problem, In Masterpage, the google analytics code were pasted before the end of body tag. In ASPX page, I need to generate a script (google addItem tracker) using codebehind ClientScript ...

Clipboard access using Javascript - sans Flash?

Is there a reliable way to access the client machine s clipboard using Javascript? I continue to run into permissions issues when attempting to do this. How does Google Docs do this? Do they use ...

javascript debugging question

I have a large javascript which I didn t write but I need to use it and I m slowely going trough it trying to figure out what does it do and how, I m using alert to print out what it does but now I ...

Parsing date like twitter

I ve made a little forum and I want parse the date on newest posts like twitter, you know "posted 40 minutes ago ","posted 1 hour ago"... What s the best way ? Thanx.

热门标签