let currentDate = new Date(); let previousDate = getDate(-1); let nextDate = getDate(1); let dates = [ JJ_CM_NS_Utility.dateLogic.formatDate(previousDate, ‘YYYY-MM-DD’), … Continue reading How to convert the date into predefined format using utility module
Tag: date conversion
SuiteScript 2.0 Error: no method getTime()
To get the date on a date or datetime field from a record such as that of startdate or lastmodifieddate, the string output from record.getValue() needs to be converted first to a date using N/format module’s format.parse() method. require([‘N/currentRecord’, ‘N/format’], function (nCurrentRecord, nFormat) { var currentRecord = nCurrentRecord.get(); var lastModifiedDateString =… Continue reading SuiteScript 2.0 Error: no method getTime()
Script to convert date to another time zone and add days to the date using single saved search formula
Script to convert date to another time zone and add days to the date using single saved search formula
Script to add five days to today’s date and convert the date to another time zone
Script to add five days to today’s date and convert date to another time zone