Answers for "getValues"

0

getValues

let SHEET = SpreadsheetApp.getActiveSpreadsheet().getActiveSheet();
  
let values = SHEET.getRange(2, 1, SHEET.getLastRow()-1, 1).getValues();
// .getRange(row, column, numRows, numColumns)
// So '.getLastRow()-1' because 'values' starts at the second row
  
let valuesDestination = SHEET.getRange(`B2:B${SHEET.getLastRow()}`)
  
valuesDestination.setValues(values);
Posted by: Guest on January-10-2021

Code answers related to "getValues"

Browse Popular Code Answers by Language