【发布时间】:2020-04-19 10:03:52
【问题描述】:
当我点击按钮数据提交时。 我正在使用这段代码,你能帮我解决这个问题吗
代码.gs
function onOpen() {
SpreadsheetApp
.getUi()
.createMenu('Sidebar')
.addItem('Contact Form', 'showSidebar')
.addToUi();
}
function showSidebar() {
var html = HtmlService
.createTemplateFromFile('sidebar')
.evaluate()
.setTitle('Contact Form');
SpreadsheetApp.getUi()
.showSidebar(html);
}
和sidebar.html
<!DOCTYPE html>
<html>
<head>
<base target="_top">
</head>
<body>
<form id="contact">
<h3>First Name</h3>
<input type="text" name="firstname">
<h3>Phone Number</h3>
<input type="text" name="phone">
<a href="#" onClick="return false;" class="fltr-button animate">Submit</a>
</form>
</body>
</html>
【问题讨论】:
-
嗨@ManishSinghal,欢迎来到StackOverFlow。请参考此stackoverflow.help/support/solutions/articles/…。
-
而且 当我点击按钮数据提交时 对我来说似乎不完整。请告诉我们您面临的问题,以便我们能够更好地帮助您。
标签: google-apps-script google-sheets