ReferenceError: "Drive" is not defined. (line 16, file "Code") in google app script

Sour LeangChhean picture Sour LeangChhean · May 8, 2017 · Viewed 9.6k times · Source

When I try to use Google drive reference it always shows ReferenceError: "Drive" is not defined. (line 16, file "Code").

Answer

Sour LeangChhean picture Sour LeangChhean · May 8, 2017

I've solves this error by go to:

Resources -> Advanced Google Services -> Enable Drive Api

enter image description here

Note: you need to Enable Drive Api in Google Console