Friday, September 21, 2018

Customize the Label of a Standard Button on a Form

A user wants to customize a label of a standard NetSuite form button. For example, he would like the Print button in a Sales Order form to be labeled "Print Sales Order" rather than "Print" only.

The user needs to create a User Event Script which is similar to this one: 
function setCustomLabelButton(type, form) {
 if(type == 'view') {
  var printButton = form.getButton('print');
  printButton.setLabel('Print Sales Order');
 }
}
 
 
He needs to deploy this script on the Before Load function of the Sales Order record.


No comments:

Post a Comment