Glide Form Methods
Glide Form Methods
The Glide Form is client side API, mainly used to change default behavior of
the current record
GlideForm methods are only running on the client side (Browser).
setValue()
getFormElement()
getValue()
getSection()
addOption()
getTableName()
removeOption()
getUniqueValue()
addInfoMessage()
hideRelatedLists()
addErrorMessage()
isMandatory()
clearMessage()
save()
clearOptions()
submit()
disableAttachments()
setDisabled()
enableAttachments()
setDisplay()
Flash()
setMandatory()
getActionName()
setVisible()
getControl()
setReadOnly()
getElement()
setSectonDisplay()
showErrorBox()
showRelatedList()
showFieldMsg()
showRelatedLists()
addDecoration()
isNewRecord()
removeOption()
hideFieldMsg()
g_form.isMandatory ('category');
g_form.disableAttachments ();
Allows customer file attachments to be added. Shows the paper clip icon.
g_form.enableAttachments ();
Removes all informational and error messages from the top of the form.
g_form.clearMessages ();
g_form.clearOptions ('category');
g_form.clearValue('category');
g_form.hideRelatedLists ();
g_form.showRelatedLists ();
g_form.isNewRecord ();
This method will display Informational or Error or Warn message under the specified
form field (either a control object or the name of the field). If the control or
field is off the screen, the form is scrolled to the field.
The showErrorBox () method is an alternate method that does not require the type
parameter.
This method will hides the last message placed by showFieldMsg ().
When true, all messages for the field are cleared. When false, only the last
message is removed.
g_form.hideFieldMsg('impact', true);//When true, all msgs for the field are cleared
//this example was run on a form divided into sections (Change form)
if (newValue == '2') {
g_form.setSectionDisplay(sections[1], false);
} else {
g_form.setSectionDisplay(sections[1], true);
Adding the same item twice is prevented; however, you can add the same icon with a
different title.