0

I am trying to convert Jan 2017 to a date of 1/1/2017 and I am hitting so many roadblocks. I can get it to be a text value of '1/1/2017' with a {formula} but when I try to do to_date({formula},'MM/DD/YYYY') it just gives an error.

Any thoughts?

o-90
  • 17,045
  • 10
  • 39
  • 63
  • 2
    Please edit the question and add the ***exact*** error you are getting. Otherwise, we are as lost as you are. – o-90 Feb 04 '17 at 16:09

1 Answers1

0

This is not exactly what you are asking for... But, why not use the NetSuite String to Date function? If you are trying to write to a date field in NetSuite, that function will provide you with the date that you are looking for.

var startDate={formula}; //No idea what your formula is.  But, you said this returns 1/1/2017;
var newDate=nlapiStringToDate(startDate);

NetSuite Date APIs

w3bguy
  • 2,215
  • 1
  • 19
  • 34