Discussions
Stay up-to-date with the latest news from NetSuite. You’ll be in the know about how to connect with peers and take your business to new heights at our virtual, in-person, on demand events, and much more.
Now is the time to ask your NetSuite-savvy friends and colleagues to join the NetSuite Support Community! Refer now! Click here to watch and learn more!
Stay in the Know
Be sure you're subscribed to NetSuite communication to stay in the know about monthly happenings, updates and announcements. Subscribe
Be sure you're subscribed to NetSuite communication to stay in the know about monthly happenings, updates and announcements. Subscribe
Script Works in Chrome but Not Firefox or Edge
Hi All
I'm new to scripting and have written a couple to compare the expected close date and line item dates on an opportunity record
One of the scripts are below which fires on line valiation.
The issue i'm having is it works great in Chrome and only alerts me if the expected close date is after the earliest line date. In Firefox and Edge it alerts me no matter what - grrr!
Any ideas whats wrong?
function ValidateLineDate()
{
var lineDate = Date.parse(nlapiGetCurrentLineItemValue('item','custcol1'));
var expectedClose = Date.parse(nlapiGetFieldValue('expectedclosedate'));
if(lineDate >= expectedClose)
{return true;}
else
0