Set Field Value from Suitelet Popup Called from Client Script

A client side script on a transaction record calls a popup Suitelet that lets you search and select an item. After selecting the item from the Suitelet, it should then set the item to the line item of the transaction record. You may use the javascript method window.opener to set value from the suitelet to… Continue reading Set Field Value from Suitelet Popup Called from Client Script

Suitelet Script Deployment Page Links Subtab

The Suitelet Script Deployment Page Links Subtab is a section in Netsuite where we can view and manage the external URLs for a Suitelet script deployment. It allows to create, edit, and delete external URLs that give external users access to a Suitelet without having to log in to Netsuite. This subtab is located in… Continue reading Suitelet Script Deployment Page Links Subtab

Calling suitelet from HTML by AJAX method (Backend function)

function fetchDetails(){ let internalIdArrayCheck=CUSTOM_IF_DETAILED_ARRAY.split(‘_’); if(internalIdArrayCheck.length==1) { console.log(‘CUSTOM_IF_DETAILED_ARRAY’,CUSTOM_IF_DETAILED_ARRAY) $.get(‘/app/site/hosting/scriptlet.nl?script=1525&deploy=1&resultData=’ +dataStringify) } setTimeout(“window.close()”, 50); } In this case, the front-end functionality will be running and closing the window, but the suite let we have called will be triggered in the backend and do the functionality. This helps the front end side much faster.

Resolve Error: “INVALID_TYPE_1_USE_2” for Custom Date/Time Field on Suitelet page if get values from client script

Description An error occurred in the script while running the suite let page after adding the date filters to get the results. SOLUTION: Use N/format module *** Get the custom date using the data type Value *** var fromDateRecValue = context.currentRecord.getValue({ fieldId: ‘custpage_fromdate’ }); *** Change the value to date format *** var fromDateRec =… Continue reading Resolve Error: “INVALID_TYPE_1_USE_2” for Custom Date/Time Field on Suitelet page if get values from client script

Dynamically Execute a Form Button using NetSuite SuiteScript 2.0

Sample SuiteScript 2.0 code to Dynamically Create Button to Fire Two SuiteLets In the code example below, using SuiteScript 2.0 it is relatively easy to see how you can hook up a button to fire not one, but two SuiteLets.  The first Suitelet does not have a user interface and performs work server side.  The… Continue reading Dynamically Execute a Form Button using NetSuite SuiteScript 2.0