Skip to content
Advertisement

Moving file appscript -> Hyperlink move to another folder – Google App Script

I am trying with all my energy to create a code where I get a hyperlink of a file (uploaded to folder in drive) and move this file depending on a conditionn (switch case statement).

When I dissect the code and create subparts every subpart works. Am Stuck.

JavaScript

Advertisement

Answer

You can’t do it with onEdit() trigger. Simply triggers can operate only within the current spreadsheet and its data.

https://developers.google.com/apps-script/guides/triggers

Simple Triggers

They cannot access services that require authorization. For example, a simple trigger cannot send an email because the Gmail service requires authorization, but a simple trigger can translate a phrase with the Language service, which is anonymous.

They can modify the file they are bound to, but cannot access other files because that would require authorization.

User contributions licensed under: CC BY-SA
1 People found this is helpful
Advertisement