migrated functionality to Spreadsheet::getSelectedName