I try to sort an array of values in google script. I got the values with .getRange().getValues(). I want to sort them ascending, but don't know how. I already tried different solutions, but nothing helped. Have maybe someone an idea? Code looks like this at the moment:
Thanks in advance
var values = simsSheet.getRange("A1:NTP1").getValues();
values.sort(function(a,b){
return a - b;
});
Logger.log(values);
aandbare?getValuesreturnsObject[Object[]]... (i.e., an array of arrays)