I am new with Google Sheets scripts and I can't seem to figure why I am getting this error: Range not found (line 4, file "Code"). I have followed everything from https://developers.google.com/apps-script/guides/sheets/functions#creating_a_custom_function
Here is my code:
function getBgColor(input) {
var ss = SpreadsheetApp.getActiveSpreadsheet();
var sheet = ss.getSheets()[0];
var range = sheet.getRange(input);
return range.getBackground();
}
I appreciate all the assistance.