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.
New AI Community Guidelines. Please review and follow them to ensure AI use stays safe, accurate, and compliant.
fieldChanged on a sublist I've created in script
I'm trying to get a lines value on field changed and for some reason it is grabbing the value prior to the change. So as an example, say I have a field called notes and it already holds the value 'foo,' I then change it to 'test' but on the fieldChanged script it grabs the value 'foo' not 'test.' Can anyone explain why this would happen?
function fieldChanged(scriptContext){ var eventRecord = scriptContext.currentRecord; var fieldId = scriptContext.fieldId; var lineNum = scriptContext.line; var fieldValue = eventRecord.getSublistValue({ sublistId: 'custpage_eventsublist', fieldId: fieldId, line: lineNum }); 0