Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

112
Views
Why i got yesterday at google app script?

im just learning google app script, and this problem really puzzling me. so, pretty please some help.

so, i am have this Google Sheet that collects responses from Google Form. This form has "Date" response on it, so i assume i always get the correct date format since it is automaticly generated ny sistem. But when i take the value in google app script, in

(DataObject[4].getDate()).toString()

it return yesterday value. so, if the value in Google sheet written "4/8/2022" i get "7" value in script app, instead of "8". (DataObject[4] is the variable where i store date value)

i already tried to add +1 in the script, like in

(DataObject[4].getDate()+1).toString()

but i got problem when the real date is "4/1/2022" the value become "32" (since march have 31 days).

is there something i did wrong?

about 4 years ago · Santiago Gelvez
1 answers
Answer question

0

You have to change timezone in your script editor.

Click o the gear on the left hand side of the script editor and check the third box enter image description here

Go back to the script, choose appsscript.json and change timezone as needed, for instance enter image description here

about 4 years ago · Santiago Gelvez Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!