fieldChanged(scriptContext)
The content in this topic applies to SuiteScript 2.0 and SuiteScript 2.1.
Description |
Defines the function that is executed when a field is changed by a user or client call. This event may also execute directly through beforeLoad user event scripts. The following sample tasks can be performed:
For an example, see SuiteScript Client Script Sample.
Note:
This event does not execute when the field value is changed or entered in the page URL. Use the pageInit function to handle URLs that may contain updated field values. See pageInit(scriptContext). |
Returns |
void |
Since |
Version 2015 Release 2 |
Parameters
The scriptContext
parameter is a JavaScript object. It is automatically passed to the script entry point by NetSuite.
Parameter |
Type |
Description |
Since |
---|---|---|---|
|
The current form record. For more information about CurrentRecord object members, see CurrentRecord Object Members. |
Version 2015 Release 2 |
|
|
string |
The sublist ID name. |
Version 2015 Release 2 |
|
string |
The field ID name. |
Version 2015 Release 2 |
|
string |
The line number (zero-based index) if the field is in a sublist or a matrix. If the field is not a sublist or matrix, the default value is undefined. |
Version 2015 Release 2 |
|
string |
The column number (zero-based index) if the field is in a matrix. If the field is not in a matrix, the default value is undefined. |
Version 2015 Release 2 |
For an example of the fieldChanged entry point, see SuiteScript Client Script Sample.
Related Topics
- SuiteScript 2.x Client Script Entry Points and API
- lineInit(scriptContext)
- pageInit(scriptContext)
- postSourcing(scriptContext)
- saveRecord(scriptContext)
- sublistChanged(scriptContext)
- validateDelete(scriptContext)
- validateField(scriptContext)
- validateInsert(scriptContext)
- validateLine(scriptContext)
- localizationContextEnter(scriptContext)
- localizationContextExit(scriptContext)