【发布时间】:2020-02-10 07:26:35
【问题描述】:
【问题讨论】:
标签: node.js google-docs-api google-apis-explorer
【问题讨论】:
标签: node.js google-docs-api google-apis-explorer
不幸的是,在现阶段,documentStyle 和content 似乎无法用documents.create 的方法设置。 Ref我确认这仍然没有被修改。那么作为当前的解决方法,下面的流程如何?
使用documents.create的方法创建新文档。在这种情况下,可以设置标题。
使用documents.batchUpdate的方法设置updateDocumentStyle。
从您的问题来看,documents.batchUpdate 的请求正文如下。
{
"requests": [
{
"updateDocumentStyle": {
"documentStyle": {
"marginTop": {
"magnitude": 100,
"unit": "PT"
},
"marginLeft": {
"magnitude": 500,
"unit": "PT"
}
},
"fields": "marginTop,marginLeft"
}
}
]
}
如果这不是您想要的方向,我深表歉意。
【讨论】: