如何制作应用脚本以立即允许访问Google Spreadsheet中的所有导入元素? [英] How can I make an apps script to instantly allow access to all imported elements in a Google Spreadsheet?

查看:92
本文介绍了如何制作应用脚本以立即允许访问Google Spreadsheet中的所有导入元素?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我必须使用Google电子表格. 我正在使用一些模板电子表格,它们都包含许多指向其他电子表格的链接. 问题是,每当我复制模板电子表格以使用大多数链接(通过importrange函数创建)时,都需要我再次赋予它们访问权限

I have to work with google spreadsheets. I am using some template spreadsheets which all contain a lot of links to other spreadsheets. The problem is that whenever I make a copy of the template spreadsheet to use most of the links(created with the importrange function) require me to give them access again

我想要做的是制作一个脚本,使我可以一键导入所有链接.我试图制作一个应用程序脚本,但找不到任何使用允许访问"按钮访问文本框的方法,以便可以编写自己的脚本.我的问题是:有什么方法可以通过编程方式访问允许访问"按钮?还是有其他方法可以解决我的问题并允许一键访问所有链接?

What I want to do is make a script that would allow me to import all the links in one press. I tried to make an app script but I can't found any way to access the textbox with the "allow access" button so that i can make my script. My questions are: is there any way to access the "allow access" button programatically? or is there any other way to solve my problem and allow access to all links in one press?

推荐答案

我不得不面对同样的问题.避免对此importrange允许访问的唯一方法是将链接的文档(importrange的目的地)公开,或由链接共享(也为公开,但如果读者拥有链接).这样就无需授权importrange. 如果这两个文档来自同一所有者,Google应该避免这种授权访问,我不知道这里的安全漏洞在哪里.

I had to face to the same issue. The only way to avoid this Allow Access for importrange is to put the linked document (destination of the importrange) public, or shared by the link, which is public too, but if readers have the link. Then there is no requirement of authorizing importrange. Google should avoid this authorization access if the 2 documents are from the same owner, I don't understand where is the security breach here.

这篇关于如何制作应用脚本以立即允许访问Google Spreadsheet中的所有导入元素?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆