JSForm

Constants Summary

TypeNameSummary

Constant used for form namedFoundset property..

The constants to set or get the view property of a JSForm..

The constants to set or get the view property of a JSForm..

The constants to set or get the view property of a JSForm..

The constants to set or get the view property of a JSForm..

The constants to set or get the view property of a JSForm..

Constant used for form selectionMode property..

Constant used for form selectionMode property..

Constant used for form selectionMode property..

Constant used for form namedFoundset property..

Property Summary

TypeNameSummary

The type, color and style of border of the component..

The names of the database server and table that this form is linked to..

Get or set the encapsulation level for the form..

A JSForm instance representing the super form of this form, if this form has a super form..

The default sort order only when the form loads..

The name of the form..

Property that tells the form to use a named foundset instead of the default foundset..

The navigator (previously named "controller") that is used to control/navigate to the form..

Get or set the ngReadonlyMode for the form..

This method is triggered when the form wants to hide; this will be called before onHide, and should be used to return if this form can be hidden or not..

The method that overrides the Servoy menu item Select > Delete All..

The method that overrides the Servoy menu item Select > Delete Record (or keyboard shortcut)..

The method that overrides the Servoy menu item Select > Duplicate Record (or keyboard shortcut)..

Method that is executed when the data in one of the form's component is successfully changed and the onDataChange callback from the component does not exist or exists and returned true.

The method that is triggered when focus is gained by a component inside the form..

The method that gets triggered when focus is lost by a component inside the form..

The method that overrides the Servoy menu item Select > Find (or keyboard shortcut) in Data (ready) mode..

This method is triggered when the form gets hidden..

The method that overrides the Servoy menu item Select > Invert Records..

The method that is triggered when a form is loaded/reloaded from the repository; used to alter elements, set globals, hide toolbars, etc; onShow method can also be assigned..

The method that overrides the Servoy menu item Select > New Record (or keyboard shortcut)..

The method that overrides the Servoy menu item Select > Next Record..

The method that overrides the Servoy menu item Select > Omit Record..

The method that overrides the Servoy menu item Select > Previous Record..

The method that is triggered when a user clicks into a column on the form..

The method that is triggered when a record is being saved..

The method that is triggered each time a record is selected..

The method that gets triggered when resize occurs..

The method that overrides the Servoy menu item Select > Search (or keyboard shortcut) in Find mode..

The method that is triggered EVERY TIME the form is displayed; an argument must be passed to the method if this is the first time the form is displayed..

The method that overrides the Servoy menu item Select > Show All (or keyboard shortcut)..

The method that overrides the Servoy menu item Select > Show Omitted Records..

The method that overrides the Servoy menu item Select > Sort..

The method that is triggered when a form is unloaded from the repository..

Returns true if this form is in responsive mode.

Scrollbar options for the vertical and horizontal scrollbars..

Returns the value of the form's selectionMode property..

Get the server name used by this form..

When set, the form is displayed under the Window menu..

The Cascading Style Sheet (CSS) class name applied to the form..

The [name of the table/SQL view]..

The text that displays in the title bar of the form window..

When set, the form is transparent..

Get or set the positioning (either use anchoring or use css position) for the form..

The default form view mode..

The width of the form in pixels..

Methods Summary

TypeNameSummary

Returns a JSLayoutContainer that has the given name throughout the whole form hierarchy..

Returns a JSWebComponent that has the given name through the whole hierarchy of JSLayoutContainers.

Returns a JSBean that has the given name..

Returns all JSBeans of this form..

Returns all JSBeans of this form..

Retrieves the Body part of the form..

Returns a JSButton that has the given name..

Returns all JSButtons of this form, including the ones without a name..

Returns all JSButtons of this form, including the ones without a name..

Returns the comment of this container..

Returns a JSComponent that has the given name; if found it will be a JSField, JSLabel, JSButton, JSPortal, JSBean, JSWebComponent or JSTabPanel..

Returns a array of all the JSComponents that a form has; they are of type JSField,JSLabel,JSButton,JSPortal,JSBean, JSWebComponents or JSTabPanel..

Returns a array of all the JSComponents that a form has; they are of type JSField,JSLabel,JSButton,JSPortal,JSBean, JSWebComponent or JSTabPanel..

Get a design-time property of a form..

Get the design-time properties of a form..

The field with the specified name..

Returns all JSField objects of this form, including the ones without a name..

Returns all JSField objects of this form, including the ones without a name..

Retrieves the Footer part of the form..

Retrieves the Header part of the form..

Returns a JSLabel that has the given name..

Returns all JSLabels of this form (not including its super form), including the ones without a name..

Returns all JSLabels of this form (optionally including it super forms labels), including the ones without a name..

Returns a JSLayoutContainer that has the given name of this container..

Returns all JSLayoutContainers objects of this container..

Returns all JSLayoutContainers objects of this container.

Retrieves the Leading Grand Summary part of the form..

Gets an array of the Leading Subsummary parts of the form, ordered by their height from top == 0 to bottom..

Gets an existing form method for the given name..

Returns all existing form methods for this form..

Returns all existing form methods for this form..

Gets a part of the form from the given type (see JSPart constants)..

Gets a part of the form from the given type (see JSPart constants)..

Returns the Y offset of a given part (see JSPart) of the form..

Returns the Y offset of a given part (see JSPart) of the form..

Gets all the parts from the form (not including the parts of the parent form), ordered by there height (lowerbound) property, from top == 0 to bottom..

Gets all the parts from the form (optionally also from the parent form), ordered by there height (lowerbound) property, from top == 0 to bottom..

Returns a JSPortal that has the given name..

Returns all JSPortal objects of this form (not including the ones from the parent form), including the ones without a name..

Returns all JSPortal objects of this form (optionally also the ones from the parent form), including the ones without a name..

Returns a JSTabPanel that has the given name..

Returns all JSTabPanels of this form (not including the ones from the parent form), including the ones without a name..

Returns all JSTabPanels of this form (optionally the ones from the parent form), including the ones without a name..

Retrieves the Title Footer part of the form..

Retrieves the Title Header part of the form..

Retrieves the Trailing Grand Summary part of the form..

Gets an array of the Trailing Subsummary parts of the form, ordered by their height from top == 0 to bottom..

Returns the UUID of this form..

Gets an existing form variable for the given name..

An array consisting of all form variables for this form..

An array consisting of all form variables for this form..

Returns a JSWebComponent that has the given name that is a child of this layout container..

Returns all JSWebComponents of this form/container..

Returns all JSWebComponents of this form/container..

Creates a new JSBean object on the form - including the name of the JSBean object; the classname the JSBean object is based on, the "x" and "y" position of the JSBean object in pixels, as well as the width and height of the JSBean object in pixels..

Creates a new button on the form with the given text, place, size and JSMethod as the onAction event triggered action..

Creates a new button on the form with the given text and JSMethod as the onAction event triggered action..

Creates a new JSField object on the form with the displayType of CALENDAR - including the dataprovider/JSVariable of the JSField object..

Creates a new JSField object on the form with the displayType of CALENDAR - including the dataprovider/JSVariable of the JSField object, the "x" and "y" position of the JSField object in pixels, as well as the width and height of the JSField object in pixels..

Creates a new JSField object on the form with the displayType of CHECK (checkbox) - including the dataprovider/JSVariable of the JSField object..

Creates a new JSField object on the form with the displayType of CHECK (checkbox) - including the dataprovider/JSVariable of the JSField object, the "x" and "y" position of the JSField object in pixels, as well as the width and height of the JSField object in pixels..

Creates a new JSField object on the form with the displayType of COMBOBOX - including the dataprovider/JSVariable of the JSField object..

Creates a new JSField object on the form with the displayType of COMBOBOX - including the dataprovider/JSVariable of the JSField object, the "x" and "y" position of the JSField object in pixels, as well as the width and height of the JSField object in pixels..

Creates a new JSField object on the form - including the dataprovider/JSVariable of the JSField object..

Creates a new JSField object on the form - including the dataprovider/JSVariable of the JSField object, the "x" and "y" position of the JSField object in pixels, as well as the width and height of the JSField object in pixels..

Creates a new Footer part on the form..

Creates a new Header part on the form..

Creates a new JSField object on the form with the displayType of HTML_AREA - including the dataprovider/JSVariable of the JSField object..

Creates a new JSField object on the form with the displayType of HTML_AREA - including the dataprovider/JSVariable of the JSField object, the "x" and "y" position of the JSField object in pixels, as well as the width and height of the JSField object in pixels..

Creates a new JSField object on the form with the displayType of IMAGE_MEDIA - including the dataprovider/JSVariable of the JSField object..

Creates a new JSField object on the form with the displayType of IMAGE_MEDIA - including the dataprovider/JSVariable of the JSField object, the "x" and "y" position of the JSField object in pixels, as well as the width and height of the JSField object in pixels..

Creates a new JSLabel object on the form - including the text of the label..

Creates a new JSLabel object on the form - including the text of the label, the "x" and "y" position of the label object in pixels, the width and height of the label object in pixels..

Creates a new JSLabel object on the form - including the text of the label, the "x" and "y" position of the label object in pixels, the width and height of the label object in pixels and a JSMethod action such as the method for an onAction event..

Create a new layout container as the last child of its parent container..

Create a new layout container..

Create a new layout container..

Create a new layout container as the last child in its parent container..

Creates a new Leading Grand Summary part on the form..

Creates a new Leading Subsummary part on the form..

Creates a new JSField object on the form with the displayType of LISTBOX - including the dataprovider/JSVariable of the JSField object..

Creates a new JSField object on the form with the displayType of LISTBOX - including the dataprovider/JSVariable of the JSField object, the "x" and "y" position of the JSField object in pixels, as well as the width and height of the JSField object in pixels..

Creates a new form JSMethod - based on the specified code..

Creates a new JSField object on the form with the displayType of MULTISELECT_LISTBOX - including the dataprovider/JSVariable of the JSField object..

Creates a new JSField object on the form with the displayType of MULTISELECT_LISTBOX - including the dataprovider/JSVariable of the JSField object, the "x" and "y" position of the JSField object in pixels, as well as the width and height of the JSField object in pixels..

Creates a new part on the form..

Creates a new JSField object on the form with the displayType of PASSWORD - including the dataprovider/JSVariable of the JSField object..

Creates a new JSField object on the form with the displayType of PASSWORD - including the dataprovider/JSVariable of the JSField object, the "x" and "y" position of the JSField object in pixels, as well as the width and height of the JSField object in pixels..

Creates a new JSPortal object on the form - including the name of the JSPortal object and the relation the JSPortal object is based on..

Creates a new JSPortal object on the form - including the name of the JSPortal object; the relation the JSPortal object is based on, the "x" and "y" position of the JSPortal object in pixels, as well as the width and height of the JSPortal object in pixels..

Creates a new JSField object on the form with the displayType of RADIOS (radio buttons) - including the dataprovider/JSVariable of the JSField object..

Creates a new JSField object on the form with the displayType of RADIOS (radio buttons) - including the dataprovider/JSVariable of the JSField object, the "x" and "y" position of the JSField object in pixels, as well as the width and height of the JSField object in pixels..

Creates a new JSField object on the form with the displayType of RTF_AREA (enables more than one line of text to be displayed in a field) - including the dataprovider/JSVariable of the JSField object, the "x" and "y" position of the JSField object in pixels, as well as the width and height of the JSField object in pixels..

Creates a new JSField object on the form with the displayType of SPINNER - including the dataprovider/JSVariable of the JSField object..

Creates a new JSField object on the form with the displayType of SPINNER - including the dataprovider/JSVariable of the JSField object, the "x" and "y" position of the JSField object in pixels, as well as the width and height of the JSField object in pixels..

Creates a new JSTabPanel object on the form - including the name of the JSTabPanel object..

Creates a new JSTabPanel object on the form - including the name of the JSTabPanel object, the "x" and "y" position of the JSTabPanel object in pixels, as well as the width and height of the JSTabPanel object in pixels..

Creates a new JSField object on the form with the displayType of TEXT_AREA - including the dataprovider/JSVariable of the JSField object..

Creates a new JSField object on the form with the displayType of TEXT_AREA - including the dataprovider/JSVariable of the JSField object, the "x" and "y" position of the JSField object in pixels, as well as the width and height of the JSField object in pixels..

Creates a new JSField object on the form with the displayType of TEXT_FIELD - including the dataprovider/JSVariable of the JSField object..

Creates a new JSField object on the form with the displayType of TEXT_FIELD - including the dataprovider/JSVariable of the JSField object, the "x" and "y" position of the JSField object in pixels, as well as the width and height of the JSField object in pixels..

Creates a new Title Footer part on the form..

Creates a new Title Header part on the form..

Creates a new Trailing Grand Summary part on the form..

Creates a new Trailing Subsummary part on the form..

Creates a new JSField object on the form with the displayType of TYPE_AHEAD - including the dataprovider/JSVariable of the JSField object..

Creates a new JSField object on the form with the displayType of TYPE_AHEAD - including the dataprovider/JSVariable of the JSField object, the "x" and "y" position of the JSField object in pixels, as well as the width and height of the JSField object in pixels..

Creates a new form JSVariable - based on the name of the variable object and the number type, uses the SolutionModel JSVariable constants..

Creates a new form JSVariable - based on the name of the variable object , the type and it's default value , uses the SolutionModel JSVariable constants..

Creates a new JSWebComponent (spec based component) object on the RESPONSIVE form..

Creates a new JSWebComponent (spec based component) object on the RESPONSIVE form..

Creates a new JSWebComponent (spec based component) object on a form..

Creates a new JSWebComponent (spec based component) object on the RESPONSIVE form..

Creates a new JSWebComponent (spec based component) object on the form..

Set a design-time property of a form..

Removes a JSBean that has the specified name..

Removes a JSButton that has the specified name..

Removes a component (JSLabel, JSButton, JSField, JSPortal, JSBean, JSTabpanel, JSWebComponent) that has the given name..

Clear a design-time property of a form..

Removes a JSField that has the given name..

Removes a JSLabel that has the given name..

Removes a form JSMethod - based on the specified code..

Removes a JSPart of the given type..

Removes a JSPart of the given type..

Removes a JSPortal that has the given name..

Removes a JSTabPanel that has the given name..

Removes a form JSVariable - based on the name of the variable object..

Removes a JSWebComponent that has the specified name..

Constants Details

EMPTY_FOUNDSET

Constant used for form namedFoundset property. The form that uses empty namedFoundset will initially have an empty (cleared) foundset.

Returns String

Sample

// form with empty foundset
var frmEmpty = solutionModel.newForm('products_empty', 'example_data', 'products', null, true, 640, 480);
frmEmpty.newLabel("Empty FoundSet",10,10,200,20);
frmEmpty.newField('categoryid',JSField.TEXT_FIELD,10,40,200,20);
frmEmpty.newField('productname',JSField.TEXT_FIELD,10,70,200,20);
frmEmpty.namedFoundSet = JSForm.EMPTY_FOUNDSET;

LIST_VIEW

The constants to set or get the view property of a JSForm. They are as follows: JSForm.LIST_VIEW, JSForm.LOCKED_LIST_VIEW, JSForm.LOCKED_RECORD_VIEW, JSForm.LOCKED_TABLE_VIEW, JSForm.RECORD_VIEW.

Returns Number

Sample

var myListViewForm = solutionModel.newForm('newForm1', myDatasource, myStyleName, false, 800, 600);
myListViewForm.view = JSForm.LIST_VIEW;

var myLockedListViewForm = solutionModel.newForm('newForm2', myDatasource, myStyleName, false, 800, 600);	
myLockedListViewForm.view = JSForm.LOCKED_LIST_VIEW;

var myLockedRecordViewForm = solutionModel.newForm('newForm3', myDatasource, myStyleName, false, 800, 600);
myLockedRecordViewForm.view = JSForm.LOCKED_RECORD_VIEW;

var myLockedTableViewForm = solutionModel.newForm('newForm4', myDatasource, myStyleName, false, 800, 600);
myLockedTableViewForm.view = JSForm.LOCKED_TABLE_VIEW;

var myRecordViewForm = solutionModel.newForm('newForm5', myDatasource, myStyleName, false, 800, 600);
myRecordViewForm.view = JSForm.RECORD_VIEW;