Insert Data Validation using Google Apps Script

2019-09-01 08:09发布

I'm trying to insert an in cell dropdown menu (Data > Validation > List of Items) in a Gsheet using Google Apps Script. I want to do this because every time I use the spreadsheet the 'list of items' will change slightly and I don't wanna have to go to "Data > Validation > List of Items" every time I open the spreadsheet.

I'm aware that "Data > Validation > List from a Range" exists but I'd rather not use it.