我正在尝试使用Google Form API。当我尝试使用FormApp.openByUrl()时。但我要买一台ReferenceError。下面是我的代码:
我已经尝试导入API了。但它并没有起作用。
<html>
<head>
<title>Test</title>
<script src="https://apis.google.com/js/api.js"></script>
</head>
<body>
<script>
var form = FormApp.openByUrl('https://docs.google.com/forms/d/SOME-FORM/edit');
var formResponses = form.getResponses();
</script>
</body>
</html>控制台输出:
Uncaught ReferenceError: FormApp is not defined
at (index):9
(anonymous) @ (index):9它应该什么都不做,但是它抛出了一个异常。
发布于 2019-04-05 21:25:50
您尝试使用的API用于通过脚本编辑器嵌入到Google表单中的脚本。

它与脚本https://apis.google.com/js/api.js无关,后者用于从其他网站连接到Google。
https://stackoverflow.com/questions/55535880
复制相似问题