March 2017
Beginner
358 pages
9h 51m
English
Getting and setting values from a client script running on a form can be accomplished using a few different methods of the g_form class, each of which serves a different purpose:
The getValue() method accepts one argument: the name (not to be confused with the label) of the field. It simply returns the value that the field contains. If the field is a reference field, the value will be a sys_id. If it's an integer drop-down list like the State field, you'll get the number corresponding to the currently selected choice returned, always cast to a string.
The setValue() method of the g_form class, as you might expect, is just the opposite of the getValue() method. It accepts two arguments instead of one ...
Read now
Unlock full access