Singuan Iap
Singuan Iap

Reputation: 31

Get url of the web app

In Google Spreadsheet, with the google-app-script, we can get the spreadsheet id by: SpreadsheetApp.getActiveSpreadsheet().getId()

On the other hand, how to get the url of the web app in the spreadsheet? With that, I can show the url in some cell of the spreadsheet.

Upvotes: 1

Views: 711

Answers (1)

Wim den Herder
Wim den Herder

Reputation: 1305

 var webAppUrl = ScriptApp.getService().getUrl();

You will find the documentation here:

https://developers.google.com/apps-script/reference/script/service

Upvotes: 1

Related Questions