当我使用以下内容时,便会创建工作表,但标题尚未设置。
当我使用api Explorer时,它会以正确的标题创建。使用本文档: https://developers.google.com/sheets/api/reference/rest/v4/spreadsheets/create?apix_params=%7B%22resource%22%3A%7B%22properties%22%3A%7B%22title%22%3A%22x%22%7D%7D%7D
var request = gapi.client.sheets.spreadsheets.create({ "properties": { "title": "x" } }, {});
在响应中:
...
title: "Untitled spreadsheet"
...
答案 0 :(得分:0)
var request = gapi.client.sheets.spreadsheets.create({ "properties": { "title": "x" } });
删除第二个对象是我所需要的。