Hello,
I am new to Excel Online scripts, and I'm trying to write a script that automatically renames a sheet based on the value in a cell on that sheet.
I assume I'd want to establish a variable with "let", so I'd think it would be something like the below. The Sheet Name, ideally, would be a date in mm-dd-yy format.
//Set Sheet1 (the original sheet name) to the value in cell H1
let = actualdate = sheet1.getRange("H1");
sheet1.setName(actual date);
Having issues since the setName function expects a string instead of a range. Can someone assist?
Thanks,
Mike
I am new to Excel Online scripts, and I'm trying to write a script that automatically renames a sheet based on the value in a cell on that sheet.
I assume I'd want to establish a variable with "let", so I'd think it would be something like the below. The Sheet Name, ideally, would be a date in mm-dd-yy format.
//Set Sheet1 (the original sheet name) to the value in cell H1
let = actualdate = sheet1.getRange("H1");
sheet1.setName(actual date);
Having issues since the setName function expects a string instead of a range. Can someone assist?
Thanks,
Mike