NSOA.form.getName(field)
Use this function to get the parameter name of the field.
This is generally the same as the field name, that is, the required parameter to call this function. The function is useful when working with Object Fields.
Parameters
-
field {string} [required] — The name of the field on the form.
Note:This is not the label the user sees displayed next to the field on the form. This is the name of the field displayed in the Form Schema.
Returns
-
The parameter name needed to refer to this field in user scripts.
Units Limit
-
1 unit
For more information, see Scripting Governance.
Since
-
August 17, 2013
Example
-
In this example the name returned is the same as the field name passed in, that is, budget_time.
var name = NSOA.form.getName('budget_time');
-
In this example the name is the field name for the row and column specified for the loaded_cost object. See Object Fields for more details.
// 'Primary loaded cost ' for the first row var name = NSOA.form.getName('loaded_cost')[0].cost_0;
See Code Samples for more examples.