google apps script formatting numbers code example
Example: google apps script formatting numbers
// Select all rows and columns from a spreadsheet
var range = sheet.getRange(1, 1, sheet.getMaxRows(), sheet.getMaxColumns());
// Money format
range.setNumberFormat("$#,##0.00;$(#,##0.00)");