In NetSuite script functions search.lookupFields and record.submitFields() there is an option to pass multiple custom field scriptids as parameters. e.g: let fieldLookUp = search.lookupFields({ type: search.Type.SALES_ORDER, id: ‘101’, columns: [‘custbody_1’, ‘custbody_2’, ‘custbody_3’, ‘custbody_4’] }); record.submitFields({ type: record.Type.SALES_ORDER, id: 101, values: { ‘custbody_1’: ‘Hello from custom field’, ‘custbody_2’: ‘Test’, ‘custbody_3’: 254, ‘custbody_4’: ‘1’ } }); But… Continue reading How to use variables for custom fields inside NetSuite search.lookupFields and record.submitFields()
Tag: record.submitfields
Common Function for Updating NetSuite Record Fields using record.submitFields
Function to Update Record Fields /** * Common function to update record fields using record.submitFields * @param {string} recordType – The type of the record (e.g., ‘customer’, ‘salesorder’) * @param {string} recordId – The internal ID of the record * @param {Object} fieldValues – Key-value pairs of fields to update * @returns {string} – The… Continue reading Common Function for Updating NetSuite Record Fields using record.submitFields