Discussions
Read on for the latest updates including:
• Agenda Builder launch
• SuiteWorld On Air registration
• New NetSuite Prompt Studio Contest
• And more!
Check out this thread to learn more!
change Addressee/Attention in Addressbook
Hi
Hope someone could help me with this netsuite script in
Customer User Event :
I try to change the value in Addressee or Attention field in Addressbook
using the following code :
METHOD 1:
var rec = nlapiGetNewRecord();
var customerId = rec.getId();
var custo=nlapiLoadRecord('customer',customerId);
custo.selectNewLineItem('addressbook');
custo.setCurrentLineItemValue('addressbook','addressee','My addressee Name');
custo.commitLineItem('addressbook');
nlapiLogExecution('debug', 'modify addressee', ' id::' + customerId );
METHOD 2:
custo.SelectLineItem('addressbook',1);
nlapiSetCurrentLineItemValue('addressbook','addressee', 'Bill Contact');
nlapiCommitLineItem('addressbook');
nlapiLogExecution('debug', 'Change addressee in Billing', ' id::' + customerId );
METHOD 3:
nlapiSubmitField('customer',customerId,'billaddressee', 'Biller Name');
I have execute all methods above and have no error, Look like it saves the value to Sandbox. But when I review the address record, the value does not change at all. Still exactly the same as before.