This is related to this thread. I don't know what the problem is since I'm just new with this coding thing. But I found the error when I clicked the latest code
below the URL.
This is the error TypeError: this[e.parameter.run] is not a function (line 2, file "Code")
.
And, this is the code:
function doGet(e) {
this[e.parameter.run](e.parameter.sheetName || null); //this is line 2
return ContentService.createTextOutput();
}
Honestly, I don't know what that function does since I just copy it on this solution. But as far as I understand, it helps for the script to be accessible to other users. What seems to be the problem here?
You function doGet(e)
expects a parameter run
to which the name of an (existing) function is assigned.
latest code
) the function will errorCurrent web app URL
and append to it ?run=NameOfFunction
https://script.google.com/macros/s/XXXXXXXX/exec?run=myFunction
myFunction()
- this function will be executed on pasting the full Web App URL including parameter run
into the browser address bar.Recomendation
return ContentService.createTextOutput();
to return ContentService.createTextOutput("It worked");