Command Summary | |
---|---|
#onDeleteAllRecords The method that overrides the Servoy menu item Select > Delete All. |
|
#onDeleteRecord The method that overrides the Servoy menu item Select > Delete Record (or keyboard shortcut). |
|
#onDuplicateRecord The method that overrides the Servoy menu item Select > Duplicate Record (or keyboard shortcut). |
|
#onFind The method that overrides the Servoy menu item Select > Find (or keyboard shortcut) in Data (ready) mode. |
|
#onInvertRecords The method that overrides the Servoy menu item Select > Invert Records. |
|
#onNewRecord The method that overrides the Servoy menu item Select > New Record (or keyboard shortcut). |
|
#onNextRecord The method that overrides the Servoy menu item Select > Next Record. |
|
#onOmitRecord The method that overrides the Servoy menu item Select > Omit Record. |
|
#onPreviousRecord The method that overrides the Servoy menu item Select > Previous Record. |
|
#onPrintPreview The method that overrides the Servoy menu item File > Print Preview. |
|
#onSearch The method that overrides the Servoy menu item Select > Search (or keyboard shortcut) in Find mode. |
|
#onShowAllRecords The method that overrides the Servoy menu item Select > Show All (or keyboard shortcut). |
|
#onShowOmittedRecords The method that overrides the Servoy menu item Select > Show Omitted Records. |
|
#onSort The method that overrides the Servoy menu item Select > Sort. |
Event Summary | |
---|---|
Number | #onDrag The method that is triggered when (non Design Mode) dragging occurs. |
#onDragEnd The method that is triggered when (non Design Mode) dragging end occurs. |
|
Boolean | #onDragOver The method that is triggered when (non Design Mode) dragging over a component occurs. |
Boolean | #onDrop The method that is triggered when (non Design Mode) dropping occurs. |
Boolean | #onElementFocusGained The method that is triggered when focus is gained by a component inside the form. |
Boolean | #onElementFocusLost The method that gets triggered when focus is lost by a component inside the form. |
Boolean | #onHide The method that is triggered when another form is being activated. |
#onLoad 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. |
|
Boolean | #onRecordEditStart The method that is triggered when a user clicks into a column on the form. |
Boolean | #onRecordEditStop The method that is triggered when a record is being saved. |
#onRecordSelection The method that is triggered each time a record is selected. |
|
#onRender The method that is executed when the component is rendered. |
|
#onResize The method that gets triggered when resize occurs. |
|
#onShow 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. |
|
#onUnLoad The method that is triggered when a form is unloaded from the repository. |
Property Summary | |
---|---|
String | #borderType The type, color and style of border. |
String | #dataSource The names of the database server and table that this form is linked to. |
String | #defaultPageFormat The default page format for the form. |
Number | #encapsulation The encapsulation mode for the form (see JSForm constants for encapsulation mode constants). |
Number | #extendsForm The selected parent (extended element) for the element (form). |
String | #initialSort The default sort order only when the form loads. |
String | #name The name of the form. |
String | #namedFoundSet Property that tells the form to use a named foundset instead of the default foundset. |
Number | #navigator The navigator (previously named "controller") that is used to control/navigate to the form. |
Number | #paperPrintScale The percentage value the printed page is enlarged or reduced to; the size of the printed form is inversely proportional. |
String | #rowBGColorCalculation The calculation dataprovider used to add background color and highlight selected or alternate rows. |
Number | #scrollbars Scrollbar options for the vertical and horizontal scrollbars. |
Number | #selectionMode Returns the value of the selectionMode property. |
Boolean | #showInMenu When set, the form is displayed under the Window menu. |
String | #styleClass The Cascading Style Sheet (CSS) class name applied to the form. |
String | #styleName The name of the Servoy style that is being used on the form. |
String | #titleText The text that displays in the title bar of the form window. |
Boolean | #transparent When set, the form is transparent. |
Number | #view The default form view mode. |
Number | #width The width of the form in pixels. |
Command Details |
---|
onDeleteAllRecords |
The method that overrides the Servoy menu item Select > Delete All.
This property is automatically set to "DEFAULT" (no override) when the form is created. |
Parameters {JSEvent} event – the event that triggered the action
|
onDeleteRecord |
The method that overrides the Servoy menu item Select > Delete Record (or keyboard shortcut).
This property is automatically set to "DEFAULT" (no override) when the form is created. |
Parameters {JSEvent} event – the event that triggered the action
|
onDuplicateRecord |
The method that overrides the Servoy menu item Select > Duplicate Record (or keyboard shortcut).
This property is automatically set to "DEFAULT" (no override) when the form is created. |
Parameters {JSEvent} event – the event that triggered the action
|
onFind |
The method that overrides the Servoy menu item Select > Find (or keyboard shortcut) in Data (ready) mode.
This property is automatically set to "DEFAULT" (no override) when the form is created. |
Parameters {JSEvent} event – the event that triggered the action
|
onInvertRecords |
The method that overrides the Servoy menu item Select > Invert Records.
This property is automatically set to "DEFAULT" (no override) when the form is created. |
Parameters {JSEvent} event – the event that triggered the action
|
onNewRecord |
The method that overrides the Servoy menu item Select > New Record (or keyboard shortcut).
This property is automatically set to "DEFAULT" (no override) when the form is created. |
Parameters {JSEvent} event – the event that triggered the action
|
onNextRecord |
The method that overrides the Servoy menu item Select > Next Record.
This property is automatically set to "DEFAULT" (no override) when the form is created. |
Parameters {JSEvent} event – the event that triggered the action
|
onOmitRecord |
The method that overrides the Servoy menu item Select > Omit Record.
This property is automatically set to "DEFAULT" (no override) when the form is created. |
Parameters {JSEvent} event – the event that triggered the action
|
onPreviousRecord |
The method that overrides the Servoy menu item Select > Previous Record.
This property is automatically set to "DEFAULT" (no override) when the form is created. |
Parameters {JSEvent} event – the event that triggered the action
|
onPrintPreview |
The method that overrides the Servoy menu item File > Print Preview.
This property is automatically set to "DEFAULT" (no override) when the form is created. |
Parameters {JSEvent} event – the event that triggered the action
|
onSearch |
The method that overrides the Servoy menu item Select > Search (or keyboard shortcut) in Find mode.
This property is automatically set to "DEFAULT" (no override) when the form is created. |
Parameters |
onShowAllRecords |
The method that overrides the Servoy menu item Select > Show All (or keyboard shortcut).
This property is automatically set to "DEFAULT" (no override) when the form is created. |
Parameters {JSEvent} event – the event that triggered the action
|
onShowOmittedRecords |
The method that overrides the Servoy menu item Select > Show Omitted Records.
This property is automatically set to "DEFAULT" (no override) when the form is created. |
Parameters {JSEvent} event – the event that triggered the action
|
onSort |
The method that overrides the Servoy menu item Select > Sort.
This property is automatically set to "DEFAULT" (no override) when the form is created. |
Parameters |
Event Details |
---|
onDrag |
The method that is triggered when (non Design Mode) dragging occurs.
|
Parameters {JSDNDEvent} event – the event that triggered the action
|
Returns |
onDragEnd |
The method that is triggered when (non Design Mode) dragging end occurs.
|
Parameters {JSDNDEvent} event – the event that triggered the action
|
onDragOver |
The method that is triggered when (non Design Mode) dragging over a component occurs.
|
Parameters {JSDNDEvent} event – the event that triggered the action
|
Returns |
onDrop |
The method that is triggered when (non Design Mode) dropping occurs.
|
Parameters {JSDNDEvent} event – the event that triggered the action
|
Returns |
onElementFocusGained |
The method that is triggered when focus is gained by a component inside the form.
|
Parameters {JSEvent} event – the event that triggered the action
|
Returns |
onElementFocusLost |
The method that gets triggered when focus is lost by a component inside the form.
|
Parameters {JSEvent} event – the event that triggered the action
|
Returns |
onHide |
The method that is triggered when another form is being activated.
NOTE: If the onHide method returns false, the form can be prevented from hiding. For example, when using onHide with showFormInDialog, the form will not close by clicking the dialog close box (X). |
Parameters {JSEvent} event – the event that triggered the action
|
Returns |
onLoad |
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. NOTE: onShow should be used to access current foundset dataproviders; onLoad cannot be used because the foundset data is not loaded until after the form is loaded. Also calls to loadRecords() should be done in the onShow method and not in the onLoad method If you call loadRecords() in the onShow method, you may want to set the namedFoundSet property of the form to 'empty' to prevent the first default form query. NOTE: the onLoad event bubbles down, meaning that the onLoad is first fired on the parent then on a tab in a tabpanel (and in tab of that tab panels if you are 3 deep) |
Parameters {JSEvent} event – the event that triggered the action
|
onRecordEditStart |
The method that is triggered when a user clicks into a column on the form.
NOTE: There is a small "e" displayed in the lower left side of the Servoy Client screen in the status area at the bottom of the window when the record is being edited. |
Parameters {JSEvent} event – the event that triggered the action
|
Returns |
onRecordEditStop |
The method that is triggered when a record is being saved.
A record is saved when a user clicks out of it (for example on an empty part of the layout or to another form). When the method returns false (for example as part of a validation), the user cannot leave the record, for example in a table view a user cannot move to another record when the callback returns false. |
Parameters |
Returns |
onRecordSelection |
The method that is triggered each time a record is selected.
If a form is in List view or Special table view - when the user clicks on it. In Record view - after the user navigates to another record using the slider or clicks up or down for next/previous record. NOTE: Data and Servoy tag values are returned when the onRecordSelection method is executed. |
Parameters {JSEvent} event – the event that triggered the action
|
onRender |
The method that is executed when the component is rendered.
|
Parameters {JSRenderEvent} event – the render event
|
onResize |
The method that gets triggered when resize occurs.
|
Parameters {JSEvent} event – the event that triggered the action
|
onShow |
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. NOTE: onShow can be used to access current foundset dataproviders; onLoad cannot be used because the foundset data is not loaded until after the form is loaded. NOTE: the onShow event bubbles down, meaning that the onShow event of a form displayed in a tabPanel is fired after the onShow event of the parent. |
Parameters |
onUnLoad |
The method that is triggered when a form is unloaded from the repository.
NOTE: Forms can be prevented from being removed from memory by referencing the form object in a global variable or inside an array inside a global variable. Do take care using this technique. Forms take up memory and if too many forms are in memory and cannot be unloaded, there is a possibility of running out of memory. |
Parameters {JSEvent} event – the event that triggered the action
|
Property Details |
---|
borderType |
The type, color and style of border.
This property is automatically set to "DEFAULT" when a new form is created. |
Returns |
dataSource |
The names of the database server and table that this form is linked to.
|
Returns |
defaultPageFormat |
The default page format for the form.
|
Returns |
encapsulation |
The encapsulation mode for the form (see JSForm constants for encapsulation mode constants).
|
Returns Number – the encapsulation mode/level for the form
|
extendsForm |
The selected parent (extended element) for the element (form).
|
Returns Number – the parent
|
initialSort |
The default sort order only when the form loads.
This is applied each time an internal SQL query is being executed (find, find-all, open form); and is only executed when no other manual sort has been performed on the foundset. |
Returns |
name |
The name of the form.
|
Returns |
namedFoundSet |
Property that tells the form to use a named foundset instead of the default foundset.
When "separate" as special value is specified the form will always create a copy of assigned foundset and therefor become separated from other foundsets. When "empty" it will initially load an empty foundset. When a global relation name it will load the a related foundset. |
Returns |
navigator |
The navigator (previously named "controller") The following options are available: |
Returns |
paperPrintScale |
The percentage value the printed page is enlarged or reduced to; the size of the printed form
is inversely proportional. For example, if the paperPrintScale is 50, the printed form will be enlarged 200%. |
Returns |
rowBGColorCalculation |
The calculation dataprovider used to add background color and highlight selected or alternate rows. NOTE: This property has been deprecated and is kept visible for legacy purposes. Use CSS Row Styling & onRender event instead. |
Returns |
scrollbars |
Scrollbar options for the vertical and horizontal scrollbars. Each of the
vertical and horizontal scrollbars can be configured to display all the time, to display only when needed or to never display. |
Returns |
selectionMode |
Returns the value of the selectionMode property.
|
Returns Number – one of IForm#SELECTION_MODE_DEFAULT, IForm#SELECTION_MODE_SINGLE and IForm#SELECTION_MODE_MULTI.
|
showInMenu |
When set, the form is displayed under the Window menu.
If it is not set, the form will be 'hidden'. NOTE: This is only applicable for Servoy Client. Servoy Developer always shows all forms so that developers have access to all forms within a solution during development. |
Returns |
styleClass |
The Cascading Style Sheet (CSS) class name applied to the form.
|
Returns |
styleName |
The name of the Servoy style that is being used on the form.
|
Returns |
titleText |
The text that displays in the title bar of the form window.
NOTE: Data tags and Servoy tags can be used as part of the title text. |
Returns |
transparent |
When set, the form is transparent.
|
Returns |
view |
The default form view mode. The view can be changed using a method at runtime. The following views are available: NOTE: Only Table View (locked) uses asynchronized related data loading. |
Returns |
width |
The width of the form in pixels.
|
Returns |