1
votes

I use Zapier to create a new row in a Google Sheet doc for each new registration on our website. However, I want to autoreplace a value of a cell when the row is created or, if it's not possible, using a script with onOpen, or any time-based trigger.

Here is an example of the data that needs to be changed in two specific columns (say, A and C)...

/*Job - Column A - English to French*/
 'Management':'Gestion',
 'Social work':'Travail social',
 'Reception':'Accueil',
 'Art Therapy':'Art-thérapie',
 'Volunteer work':'Bénévole',

/*Workplace - Column C - English to French*/
'Starting Community':'Communauté en démarrage',
'CLAN Program' : 'Programme FER',
'Other (specify)' : 'Autre affiliation',
'University (specify)' : 'Université',
  

How can I do that? I managed to use an onEdit trigger, but since it can't be activated by Zapier, it's useless.

Thanks!

1

1 Answers

0
votes

You cannot achieve this behavior with an Edit trigger in Apps Script.

Zapier will edit the Spreadsheet via API call and this is actually one of the trigger limitations:

Script executions and API requests do not cause triggers to run. For example, calling Range.setValue() to edit a cell does not cause the spreadsheet's onEdit trigger to run.

You should probably craft this auto-replace feature in the Zapier environment directly.

Refer to this documentation for additional Apps Script triggers limitations.