SuiteScript is a scripting language that is based on JavaScript which allows users to customize and extend NetSuite functionality by writing scripts that interact with NetSuite objects such as Fields, Sublists, etc. Fields are one of the basic NetSuite objects that may contain data that is important to business functions, and is commonly interacted with in NetSuite. Some fields support being accessed, manipulated, or both through the SuiteScript API.
To check if you have the correct Field ID to use in SuiteScript, you can use the Browser Console.
See the solution and screenshots below for an example implementation for the given scenario.
Scenario: User wants to verify if "tranid" refers to the Order # Field on the Sales Order (Screenshot 1)
Solution:
1. In Edit Mode, press F12 on your keyboard to open the Browser Console
2. Type nlapiGetFieldValue("tranid"); in the console then hit Enter (Screenshot/GIF 2)
"tranid" Field ID is same as in SuiteScript since it has returned the same value, "179". (Screenshot 3)
Do you have another way on how to check the Field ID in SuiteScript without using the SuiteScript Records Browser? Feel free to share your own tips and tricks under NetSuite Admin Corner to help other members as well.