Discussions
Join us for complimentary one-day events around the world and step into a future fueled by AI and limitless potential. Explore new breakthroughs, sharpen your skills, and connect with experts who are shaping what’s next. Experience bold keynotes, interactive learning, and connections that span the global NetSuite community. Discover what's next at SuiteConnect Tour 2026.
How to use the search module in a function in client script?
Hello NetSuite Guru,
I created a button for the sales order form from User Event script, when user clicks on that button, the logic will be processed from a function in the client script attached on that form.
In the function to process the button, I created a search but NetSuite showed the error: Uncaught SyntaxError: illegal character U+200C
Here is the button I created in User event script:
context.form.addButton({
id: "custpage_overwrite_amt_button",
label: "Update amount",
functionName: 'updateAmt('+ recordId + ')'
});
context.form.clientScriptModulePath = "SuiteScripts/CustomerClientScript";
And in the CustomerClientScript.js client script, the updateAmt function creates the search as below: