Good day to all.
Can someone assist with an issue I am facing for changing named ranges on multiple google sheets.
Is the easiest way to remove the named range and and apply a new named range in the correct cell
or, to modify the existing named range i.e. change the cell reference?
The scrip is not directly associated to any sheet, but is linked to a master list of google URLS.
I am trying to adapt a sample script from
here:
// The code below creates a new named range "foo", and then remove it.
var ss = SpreadsheetApp.getActiveSpreadsheet();
ss.setNamedRange("foo", ss.getActiveRange());
ss.removeNamedRange("foo");
However, I get an error "Cannot function SetNamedRange in object sheet"
any help is gratefully received