Resolving the “elem._marshal is not a function” Error in NetSuite

Error Message: “elem._marshal is not a function” This error typically occurs when a script expects a certain data type (e.g., a string or a single value) but receives a different type (e.g., an object or an array). Common Scenario This error can happen while using the search.create function in NetSuite. It occurs when a parameter… Continue reading Resolving the “elem._marshal is not a function” Error in NetSuite

Adding Striping to Line Items in Advanced Templates

1.Open the advanced template in the template editor, and click the Source Code toggle. 2.Scroll down to the portion of the HTML markup source relating to the rows in the line items table: 3.Edit the <tr> tag relating to rows in the line items table, to specify alternating colors for these rows, like the following example: <tr style=”background-color: ${((item_index… Continue reading Adding Striping to Line Items in Advanced Templates

Document Number is Different from Transaction Number

If  Allow Override checkbox is set to True for the Document Number of a record (Using Administrator role check it via Setup >Company > Auto-Generated Numbers > Document Numbers tab > Allow Override box is checked), numbering might have been altered since this is the external number. However, for future transactions: There is the ability to reset the initial number on either the Document Number or Transaction Number to be the same and all newly created transactions will… Continue reading Document Number is Different from Transaction Number

Created from to Customer Refund suitescript

Create a Transaction List/Record field. Write a user event script. Within beforeLoad :   let customerRefundId1 = context.newRecord;                   let credit = customerRefundId1.getValue({ fieldId: ‘entryformquerystring’ });                   let credId = extractCredId(credit); function extractCredId(inputString) {         var… Continue reading Created from to Customer Refund suitescript

Tracking numbers on an Item Fulfillment

To get all tracking numbers on an Item Fulfillment, you should account for all the possible tracking numbers. There are three that NetSuite uses: transaction.package transaction.packageups transaction.packagefedex The actual tracking link is referenced in with FreeMarker like this: <#list transaction.package as pkg>${pkg.packagetrackingnumber}</#list> <#list transaction.packageups as pkg>${pkg.packagetrackingnumberups}</#list> <#list transaction.packagefedex as pkg>${pkg.packagetrackingnumberfedex}</#list> I list each package tracking… Continue reading Tracking numbers on an Item Fulfillment

Customize standard item fulfillment email

Preference is called SEND ORDER FULFILLED CONFIRMATION EMAILS and is found under Setup > Accounting > Preferences > Accounting Preferences, in the Order Management, Fulfillment section. If that is enabled then all you can do is customise the template with limited access to fields.   The fields are: {1} is replaced with the customer name.… Continue reading Customize standard item fulfillment email