Home > Enterprise >  Google Apps Script Sheet extract numbers as string
Google Apps Script Sheet extract numbers as string

Time:06-27

So I'm new to Google apps script and i'm trying to extract from a sheet a range of numbers but i want to extract them as string the way they are written on the sheet. I used the getValues() function as such but the numbers are getting formatted example 12 becomes 12.0 and long ints like 14500536 becomes 14500536E7

  var X=sheet.getSheets()[0].getRange(5,1,lastrow-4);
  var rawX=X.getValues();

CodePudding user response:

try:

var rawX=X.getDisplayValues();
  • Related