您请求访问的页面目前没有您的语言版本。您可以从页面底部选择其他语言,或使用 Google Chrome 的内置翻译功能将网页内容即时翻译成您选择的语言。

Use the AppSheet Apps Script Examples Project

Quick start

 Copy the sample project as a starting point for your own Apps Script project.

  1. Open the sample project:

    Open Sample Project
     
  2. Copy the project. 

What does this sample project do?

This project has many different functions to help you get started, you can modify and mix-and-match these depending on your workflow.

Function Name

Description

sayHello

Logs a message to the console

createCalendarEvent

Adds an event to the default calendar with the provided start and end times

createDoc

Creates a Google Doc

createSheet

Creates a Google Sheet

createSlideDeck

Creates a Google Slide

shareFile

Shares a Google Drive file with an email

sendAnEmail

Sends an email

createAndSendDocument

Creates a Google Doc and send an email with it as an attachment

How to test from Apps Script

You can test executing the function from the Apps Script by clicking Run or Debug at the top of the editor:

Run and debug in Apps Script editor

Since it runs the function without setting arguments, you'll need to add default arguments. For example, instead of function sayHello(msg) change it to be function sayHello(msg="Test message").

The first time you do this, you'll need to authorize scopes the script needs. 

Next steps

After you have it set up, you can follow the instructions in Call Apps Script from automation to set up the task and bot inside AppSheet.

See also

Was this helpful?

How can we improve it?

Need more help?

Try these next steps:

Search
Clear search
Close search
Main menu
9716501320557218312
true
Search Help Center
true
true
true
false
false