Using SuiteScript with NetSuite Records
Every record in NetSuite includes these basic components: body fields, buttons and actions, subtabs, and sublists. The following figure shows a standard sales order record with each of the basic components indicated.

The basic components of the record are:
-
Record object
-
Body fields
-
Buttons and actions
-
Subtabs
-
Sublists
You can use SuiteScript to create each basic component and to get and set values on each component. The following table describes the basic components.
Record Component |
Corresponding SuiteScript Module |
---|---|
Record object |
N/record Module — interact with the entire record object. |
Body fields |
N/currentRecord Module — interact with the body fields on the main area of the record or on a subtab. |
Buttons and actions |
The use of SuiteScript on built-in buttons is not currently supported, but you can use these two modules together to implement a custom button: N/ui/serverWidget Module — add a new button object to a page. N/action Module — perform business logic to update the state of records in view mode. |
Subtabs |
N/ui/serverWidget Module — programmatically add fields to a NetSuite tab or add custom subtabs. |
Sublists |
N/ui/serverWidget Module — interact with “line item” sublist fields. |
For more information about NetSuite records, see Working with Records, Transactions, and Lists. For more information about using SuiteScript to interact with NetSuite records, see SuiteScript Records Guide.