Google Apps Script date format issue (Utilities.formatDate)

前端 未结 2 496
灰色年华
灰色年华 2020-12-18 00:36

I am pretty new to Google Apps Script, so please bear with me.

I am collecting daily interest rates from a bank on Google Sheets, and I am using the following code

2条回答
  •  猫巷女王i
    2020-12-18 01:10

    Solution :

    values[0][0] = Utilities.formatDate(new Date(), 
    "GMT+10:00", "yyyy-MM-dd").setNumberFormat('yyyy-mm-dd');
    

提交回复
热议问题