Home > Blockchain >  Runing Custom Function from Google Sheet showing no permission error
Runing Custom Function from Google Sheet showing no permission error

Time:03-19

Iam trying to integrate Google sheet and Calendar.I have written the function which adds event to google calendar but when i try to call that function from cell using custom function it shows this error

Exception: The script does not have permission to perform that action. Required permissions: (https://www.googleapis.com/auth/calendar || https://www.googleapis.com/auth/calendar.readonly || https://www.google.com/calendar/feeds)

I have given the above permission in Manifest file.Here my manifest:

`

"https://www.googleapis.com/auth/calendar",
"https://www.googleapis.com/auth/calendar.readonly",
"https://www.google.com/calendar/feeds",
"https://www.googleapis.com/auth/spreadsheets.currentonly",
"https://www.googleapis.com/auth/spreadsheets"

],`

The problem occurs on this Line let cal=CalendarApp.getCalendarById("ID");

How to fix this,Please Help!

CodePudding user response:

Custom Function Capabilities Do Nor include Calendar

functionality available to Custom Functions it does not include calendar. Even if you add the scope to the manifest it makes no difference if it's not in the list of the link then it's not available to a cell or custom function. Write it as a standard script and call it from a menu.

  • Related