This is the legacy 4D documentation web site. Documentations are progressively being moved to developer.4d.com

Home

 
4D v19
Dynamic Forms

Dynamic Forms  


 

Dynamic Forms are forms whose structures are defined in either a .json file or a 4D object. They are regenerated each time they are run and provide a superior level of flexibility. A few notable advantages include: 

  • Usability
    • straightforward updates
    • dynamic user modifications
    • easy reuse
    • faster searching
  • Portability
    • simplified sharing
    • can be stored in source control

Every object defined in a dynamic form, including the form itself, has one or more properties.

The following is a simple JSON file ("HW.json", stored in the Resources folder) with text, an image and a button:

{
    "windowTitle": "Hello World",
    "windowMinWidth": 220,
    "windowMinHeight": 80,
    "method": "HWexample",
    "pages": [
        null,
        {
            "objects": {
                "text": {
                "type": "text",
                "text": "Hello World!",
                "textAlign": "center",
                "left": 50,
                "top": 120,
                "width": 120,
                "height": 80
                },
                "image": {
                "type": "picture",
                "pictureFormat": "scaled",
                "picture": "/RESOURCES/Images/HW.png",
                "alignment":"center", 
                "left": 70,
                "top": 20, 
                "width":75, 
                "height":75        
                },
                "button": {
                "type": "button",
                "text": "OK",
                "action": "Cancel",
                "left": 60,
                "top": 160,
                "width": 100,
                "height": 20
                }
            }
        }
    ]
}

This form can be loaded in a dialog with the following 4D code:

 Open form window("/RESOURCES/HW.json")
 DIALOG("/RESOURCES/HW.json")

Which displays the form:

When creating forms from files, they must:

  • comply with the JSON schema. The 4D JSON form schema can be found in the 4D program folder at: Resources/formsSchema.json. It is your responsibility to verify the validity of the .json form file. See the JSON Validate command.
  • be in files with a ".json" file extension.
  • be stored inside the application package, relative to the structure file.

Notes:

  • Comments within .json files must be contained within the "comments" property. Standard coding characters for comments (i.e., "//", "/*", "'", etc.) will render the file invalid.
  • Arrays in JSON act as collections in 4D.

All file paths can be relative or absolute. They must use '/' as path delimiter and are resolved the following way:

  • A relative path must not start with '/'. It is resolved relatively to the JSON document where the path string has been found,
  • An absolute path starts with '/'. For security reasons, only "/RESOURCES" is accepted as absolute path and designates the current database resources folder. For example, "/RESOURCES/templates/myfile.json" points to the file "myfile.json" located in the current database resources folder.

Notes:

  • The name resolution is case sensitive.
  • 4D does not resolve a path to a .json file located over the network (starting with "http/https").
  • If the path is incorrect or the file is not valid per the JSON schema, an error will be generated.

Dynamic forms can contain JSON pointers. JSON pointers are automatically resolved when you call a 4D command that accepts a dynamic form as parameter (.json file path or 4D object):

For more information about JSON pointers, please refer to the Defining JSON Pointers section.

The properties listed within this section are those which provide the foundation and structure of a form.

PropertyTypeDescriptionPossible ValuesObjects Supported
inheritedFormstringDesignates the form to inherit.Name (string) of table or project form OR a POSIX path (string) to a .json file describing the form OR an object describing the formform
inheritedFormTabletableDesignates the table an inherited form will use.A table name or numberform
memorizeGeometrybooleanSaves the form parameters when the form window is closed. See Memorization of window geometryTRUE / FALSEform
windowTitlestringUsed by the Open form window command for the window title.variesform
destinationstringForm type."detailScreen", "listScreen", "detailPrinter", "listPrinter"form
pagescollectionCollection of pages (each page is an object)Page objectsform
cssstring or collectionCSS file(s) used by the formCSS file path(s) provided as a string, a collection of strings, or a collection of objects with "path" and "media" propertiesform
entryOrdercollectionCollection of form object names defining the entry order (the order in which form objects are sequentially highlighted when the user presses Tab or Ctrl/Cmd+Tab). If this property is not defined, the default entry order (based upon the object definition order for the page) is usedForm object namesform page
Markers  

Markers specify precise locations on the vertical ruler of the form. Used mainly in output forms, they control the listed information and set header, break, detail and footer areas of a form.

 

PropertyTypeDescriptionPossible ValuesObjects Supported
markerBodyintegerDetail marker positionminimum: 0form
markerBreakinteger/integer arrayBreak marker position(s)minimum: 0form
markerFooterintegerFooter marker positionminimum: 0form
markerHeaderinteger/integer arrayHeader marker position(s)integer minimum: 0; integer array minimum: 0form
Objects  

PropertyTypeDescriptionPossible ValuesObjects Supported
memorizeValueboolean Saves the value of the current object when memorizeGeometry is activated for the current form.TRUE / FALSEinput, tab, checkbox, radio, popup, splitter, list box 
namestring The name of the form object. (Optional for the form)Any name which does not belong to an already existing objectform, list box column, list box header, list box footer
textstring The title of the form objectvariestext, groupBox, button, checkbox, radio, list box header
typestringMandatory. Designates the data type of the form object."text", "rectangle", "groupBox", "tab", "line", "button", "checkbox", "radio", "dropdown", "combo", "webArea", "write", "subform", "plugin", "splitter", "buttonGrid", "progress", "ruler", "spinner", "stepper", "list", "pictureButton", "picturePopup", "listbox", "input", "view" text, rectangle, groupBox, tab, line, button, checkbox, radio, dropdown, combo, webArea, Write Pro, subform, plugin, splitter, buttonGrid, progress, ruler, spinner (Asynchronous progress bar), stepper, list, pictureButton, picturePopup, list box, input, View Pro   
variableCalculationstringAllows mathematical calculations to be performed."none", "minimum", "maximum", "sum", "count", "average", "standardDeviation", "variance", "sumSquare"list box footer
displaybooleanFalse to specify an invisible but active objectTRUE / FALSEbutton, dropdown
classstringCSS name(s)A list of space-separated words used as class selectors in css filestext, rectangle, groupBox, tab, line, button, checkbox, radio, dropdown, combo, webArea, Write Pro, subform, plugin, splitter, buttonGrid, progress, ruler, spinner (Asynchronous progress bar), stepper, list, pictureButton, picturePopup, list box, input, View Pro
Subform  

A subform is a form included in another form.


PropertyTypeDescriptionPossible ValuesObjects Supported
deletableInListbooleanSpecifies if the user can delete subrecords in a list subform.TRUE / FALSE  subform
detailFormstringName of an existing detail form. Name (string) of table or project form OR a POSIX path (string) to a .json file describing the form OR an object describing the formsubform, list box
doubleClickInEmptyAreaActionstringAction to perform in case of a double-click on an empty line of a subform."addSubrecord"subform
doubleClickInRowActionstringAction to perform in case of a double-click on a subform record."editSubrecord", "displaySubrecord"subform, list box
enterableInListbooleanSpecifies if the user can modify record data directly in the list, without having to use the associated detail formTRUE / FALSE  subform
listFormstringAn existing list subform where you can enter, view, and modify data in other tables.Name (string) of table or project form OR a POSIX path (string) to a .json file describing the form OR an object describing the formsubform
selectionModestringDesignates the options for allowing users to select records."multiple", "single", "none"subform, list box 

Action  

Action properties provide instructions for activities to be performed.

Events  

The "events" property accepts a JSON array (collection) of strings or numbers. To call an event, enter the event's name or value (see form event constant values). For exemple, "events":["onLoad"]) or "events":[1]

PropertyTypeDescriptionPossible ValuesObjects Supported
eventsString array or number arrayThe event(s) to listen for in order to trigger an action.onActivate, onAfterEdit, onAfterKeystroke, onAfterSort, onAlternateClick, onBeforeDataEntry, onBeforeKeystroke, onBeginDragOver, onBeginURLLoading, onBoundVariableChange, onClick, onCloseBox, onCloseDetail, onCollapse, onColumnMove, onColumnResize, onDataChange, onDeactivate, onDeleteAction, onDisplayDetail, onDoubleClick, onDragOver, onDrop, onEndURLLoading, onExpand, onFooterClick, onGettingFocus, onHeader, onHeaderClick, onLoad, onLoadRecord, onLongClick, onLosingFocus, onMenuSelect, onMouseEnter, onMouseLeave, onMouseMove, onMouseUp, onOpenDetail, onOpenExternalLink, onOutsideCall, onPagechange, onPluginArea, onPrintingBreak, onPrintingDetail, onPrintingFooter, onResize, onRowMove, onScroll, onSelectionChange, onTimer, onUnload, onURLFiltering, onURLLoadingError, onURLResourceLoading, onValidate, onVPReady, onWindowOpeningDeniedtab, input, button, checkbox, radio, dropDown, combo, web area, 4D Write Pro, subform, plugin, splitter, buttonGrid, progress, ruler spinner (Asynchronous progress bar), stepper, list, pictureButton, picturePopup, list box, list box column
Action  

PropertyTypeDescriptionPossible ValuesObjects Supported
actionstringTypical activities to be performed.The name of a valid standard action. See Standard actions.button, checkbox, radio, pictureButton, dropdown, picturePopup, buttonGrid, tab, list box
continuousExecutionbooleanDesignates whether or not to run the method of an object while the user is tracking the control.TRUE / FALSEprogress, ruler, stepper
draggingstringEnables dragging function."none", "custom", "automatic" (excluding list, list box)plugin, input, list, 4D Write Pro, list box
droppingstringEnables dropping function."none", "custom", "automatic" (excluding list, list box)plugin, input, list, 4D Write Pro, list box
methodstringA project method name.The name of an existing project methodtab, input, button, checkbox, radio, dropdown, combo, webarea, 4D Write Pro, subform, plugin, splitter, buttonGrid, progress, ruler, spinner (Asynchronous progress bar), stepper, list, pictureButton, picturePopup, form, listbox, view, listbox column
movableRowsbooleanAuthorizes the movement of rows during execution.TRUE / FALSElist box
sortablebooleanAllows sorting column data by clicking the header. TRUE / FALSElist box

PropertyTypeDescriptionPossible ValuesObjects Supported
borderRadiusintegerThe radius value for round rectangles.minimum:0rectangle
bottomintegerPositions an object at the bottom (centered).minimum: 0text, rectangle, groupBox, tab, line, button, checkbox, radio, dropdown, combo, webArea, write, subform, plugin, splitter, buttonGrid, progress, ruler, spinner (Asynchronous progress bar), stepper, list, pictureButton, picturePopup, list box, input
heightintegerDesignates an object's vertical sizeminimum: 0text, rectangle, groupBox, tab, line, button, checkbox, radio, dropdown, combo, webArea, write, subform, plugin, splitter, buttonGrid, progress, ruler, spinner (Asynchronous progress bar), stepper, list, pictureButton, picturePopup, list box, input
leftintegerPositions an object on the left.minimum: 0text, rectangle, groupBox, tab, line, button, checkbox, radio, dropdown, combo, webArea, write, subform, plugin, splitter, buttonGrid, progress, ruler, spinner (Asynchronous progress bar), stepper, list, pictureButton, picturePopup, list box, input
maxWidthintegerDesignates the largest size allowed for list box columns.minimum: 0list box columns
minWidthintegerDesignates the smallest size allowed for list box columns.minimum: 0list box columns
rightintegerPositions an object on the right.minimum: 0text, rectangle, groupBox, tab, line, button, checkbox, radio, dropdown, combo, webArea, write, subform, plugin, splitter, buttonGrid, progress, ruler, spinner (Asynchronous progress bar), stepper, list, pictureButton, picturePopup, list box, input
rowHeightstringSets the height of list box rows.css value unit "em" or "px" (default)list box
rowHeightAutobooleanActivates or disactivates automatic sizing for list box row height.TRUE / FALSElist box
rowHeightAutoMaxstringDesignates the largest height allowed for list box rows.css value unit "em" or "px" (default). minimum: 0list box
rowHeightAutoMinstringDesignates the smallest height allowed for list box rows.css value unit "em" or "px" (default). minimum: 0list box
rowHeightSourcevariesAn array defining different heights for the rows in a list box.Name of a 4D array variablelist box
startPointstringDesignates where a line begins."topLeft", "bottomLeft"line
topintegerPositions an object at the top (centered).minimum: 0text, rectangle, groupBox, tab, line, button, checkbox, radio, dropdown, combo, webArea, write, subform, plugin, splitter, buttonGrid, progress, ruler, spinner (Asynchronous progress bar), stepper, list, pictureButton, picturePopup, list box, input
widthintegerDesignates an objects horizontal sizeminimum: 0form, text, rectangle, groupBox, tab, line, button, checkbox, radio, dropdown, combo, webArea, write, subform, plugin, splitter, buttonGrid, progress, ruler, spinner (Asynchronous progress bar), stepper, list, pictureButton, picturePopup, list box, input

PropertyTypeDescriptionPossible ValuesObjects Supported
bottomMarginintegerVertical margin value (in pixels).minimum: 0form
formSizeAnchorstringName of the object whose position determines the size of the form. (minimum length: 1)Name of a 4D objectform
rightMarginintegerHorizontal margin value (in pixels).minimum: 0form
windowMaxHeightintegerDesignates the largest allowable height.minimum: 0form
windowMaxWidthintegerDesignates the largest allowable width.minimum: 0 form
windowMinHeightintegerDesignates the smallest allowable height.minimum: 0 form
windowMinWidthintegerDesignates the smallest allowable width.minimum: 0 form
windowSizingXstringSpecifies if the user can resize the form vertically."fixed", "variable"form
windowSizingYstringSpecifies if the user can resize the form horizontally."fixed", "variable"form

PropertyTypeDescriptionPossible ValuesObjects Supported
resizablebooleanDesignates if the size of an object can be modified by the user.TRUE / FALSElist box columns
sizingXstringSpecifies if the horizontal size of the object should be moved or resized when a user resizes the form."move","grow","fixed"form, text, rectangle, groupBox, tab, line, button, checkbox, radio, dropdown, combo, webArea, write, subform, plugin, splitter, buttonGrid, progress, ruler, spinner (Asynchronous progress bar), stepper, list, pictureButton, picturePopup, list box, input
sizingYstringSpecifies if the vertical size of the object should be moved or resized when a user resizes the form."move","grow","fixed"form, text, rectangle, groupBox, tab, line, button, checkbox, radio, dropdown, combo, webArea, write, subform, plugin, splitter, buttonGrid, progress, ruler, spinner (Asynchronous progress bar), stepper, list, pictureButton, picturePopup, list box, input
splitterModestringWhen a splitter object has this property, other objects to its right (vertical splitter) or below it (horizontal splitter) are pushed at the same time as the splitter, with no stop. "resize", "move"splitter 

Value  

PropertyTypeDescriptionPossible ValuesObjects Supported
automaticInsertionbooleanEnables automatically adding a value to a list stored in memory when a user enters a value that is not found in the choice list associated with the object. TRUE / FALSEcombo, list box column
choiceListlistAssociates a choice list with a column of a list box. variesinput, dropdown, combo, list box column
currentItemSourcestringThe last selected item.Object expressionlist box
currentItemPositionSourcestringThe position of the last selected item.Number expressionlist box
dataSourcestring, or string array for hierarchical listbox columnSpecifies the source of the data.A 4D variable, field name, or an arbitrary complex language expression.tab, input, button, checkbox, radio, dropdown, combo, write, subform, plugin, splitter, buttonGrid, progress, ruler, spinner (Asynchronous progress bar), stepper, list, pictureButton, picturePopup, list box column, list box header, list box footer, list box, view
dataSourceTypeHintstringIndicates the variable type."integer", "number", "boolean", "picture", "text", date", "time", "arrayText", "collection", "object", "undefined"tab, input, button, checkbox, radio, dropdown, combo, write, subform, plugin, splitter, buttonGrid, progress, ruler, spinner (Asynchronous progress bar), stepper, list, list box, list box column, listbox footer
labelslistAssociates default values or a choice list with a column of a list box.variestab
listlistList associated to a hierarchical list form object.varieslist
listboxTypestringDesignates listbox's behavior (type)."array", "currentSelection", "namedSelection", "collection"(*)list box
saveAsstringSpecifies if the item's value or reference should be retrieved when the item is selected in a list."value"; "reference"dropdown, list box column
selectedItemsSourcestringThe selected items collection.Collection expressionlist box
selectionNamestringThe contents of the list box will be based on the selection specified.Selection namelist box
tablestring/integerUsed to specify the data source for a subform or list box. Existing table names (without "[" "]" or table ID (integer minimum: 0)subform, list box

(*) "collection" designates a list box based on a collection or an entity selection.

Display  

PropertyTypeDescriptionPossible ValuesObjects Supported
booleanFormatstringSpecifies only two possible values."TRUE"; "FALSE"input, list box column
controlTypestringSpecifies how the value should be rendered in a list box cell."input", "checkbox" (for boolean / numeric columns), "automatic", "popup" (only for boolean columns)list box column
dateFormatstringControls the way dates appear when displayed or printed. Must only be selected among the 4D built-in formats."systemShort", "systemMedium", "systemLong", "iso8601", "rfc822", "short", "shortCentury", "abbreviated", "long", "blankIfNull" (can be combined with the other possible values) input,  list box column, dropdown, combo, list box footer
numberFormatstringControls the way numbers appear when displayed or printed.Numbers (including a decimal point or minus sign if necessary)input, dropdown, combo, ruler, progress, list box column, list box footer
pictureFormatstring Controls how pictures appear when displayed or printed. "truncatedTopLeft", "scaled", "truncatedCenter", "tiled" (pictures only), "proportionalTopLeft" (excluding pictures), "proportionalCenter"(excluding pictures)picture, input, list box, list box footer
textFormatstringControls the way the alphanumeric fields and variables appear when displayed or printed."### ####", "(###) ### ####", "### ### ####", "### ## ####", "00000", custom formatsinput, combo, dropdown, list box column, list box footer
timeFormatstringControls the way times appear when displayed or printed. Must only be selected among the 4D built-in formats."systemShort", "systemMedium", "systemLong", "iso8601", "hh_mm_ss", "hh_mm", "hh_mm_am", "mm_ss", "HH_MM_SS", "HH_MM", "MM_SS", "blankIfNull" (can be combined with the other possible values) input, dropdown, list box column, list box footer
truncateModestringControls the display of values when list box columns are too narrow to show their full contents."withEllipsis"; "none"list box column, list box footer
visibilitystringAllows hiding the object in the Application environment."visible", "hidden", "selectedRows", "unselectedRows"common, list box column 
Entry  

PropertyTypeDescriptionPossible ValuesObjects Supported
contextMenustringProvides the user access to a standard context menu in the selected area."automatic", "none"input, webArea, Write, list box column
enterablebooleanAuthorizes entry.TRUE / FALSEinput, lis tbox column, list, stepper, ruler, progress, write
entryFilterstringAssociates an entry filter with the object or column cells. This property is not accessible if the Enterable property is not enabled.variesinput, combo, list, list box column
focusablebooleanEnables the object to have the focus (and can be activated by the keyboard).TRUE / FALSEinput, button, checkbox, radio, dropdown, write, subform, plugin, ruler, list, list box
keyboardDialectstringAssociates a specific keyboard layout to a field or an enterable object using language identifiers RFC 3066 Bis.variesinput, write
multilinestringDesignates if text that is too long to be displayed will be truncated (with or without line returns)."automatic", "yes", "no"input
placeholderstringText to be displayed (grayed out) when the value for dataSource is empty.variesinput, combo
shortcutAccelbooleanSpecifies the system to use, Windows or Mac.TRUE / FALSEcheckbox, radio, pictureButton
shortcutAltbooleanDesignates the Alt keyTRUE / FALSEcheckbox, radio, pictureButton
shortcutCommandbooleanDesignates the Command key (Mac)TRUE / FALSEcheckbox, radio, pictureButton
shortcutControlbooleanDesignates the Control key (Windows)TRUE / FALSEcheckbox, radio, pictureButton
shortcutKeystringThe letter or name of a special meaning key."[F1]" -> "[F15]", "[Return]", "[Enter]", "[Backspace]", "[Tab]", "[Esc]", "[Del]", "[Home]", "[End]", "[Help]", "[Page up]", "[Page down]", "[left arrow]", "[right arrow]", "[up arrow]", "[down arrow]"checkbox, radio, pictureButton
shortcutShiftbooleanDesignates the Shift keyTRUE / FALSEcheckbox, radio, pictureButton
showSelectionbooleanKeeps the selection visible within the object after it has lost the focus. TRUE / FALSEinput, write
singleClickEditbooleanEnables direct passage to edit mode.TRUE / FALSElist box
spellcheckbooleanSpecifies if spelling will be automatically verified or not.TRUE / FALSEinput, write

PropertyTypeDescriptionPossible ValuesObjects Supported
excludedListlistAllows setting a list whose values cannot be entered in the column. If an excluded value is entered, it is not accepted and an error message is displayed. variesinput, combo, list box column
maxstring / numberThe maximum allowed value. For numeric steppers, these properties represent seconds when the object is associated with a time type value and are ignored when it is associated with a date type value.variesinput, progress, ruler, stepper
minstring / numberThe minimum allowed value. For numeric steppers, these properties represent seconds when the object is associated with a time type value and are ignored when it is associated with a date type value.variesinput, progress, ruler, stepper
requiredListlistAllows setting a list where only these values can be inserted. When a required list is defined, keyboard entry is no longer possible.variesinput, listbox column

Look  

PropertyTypeDescriptionPossible ValuesObjects Supported
defaultButtonbooleanSimilar to a standard button except that it has a modified appearance, intended to indicate the recommended choice to the user.TRUE / FALSEbutton
dpistringSets the screen resolution for the 4D Write Pro area contents.0, 72, 964D Write Pro 
hideFocusRingbooleanDuring execution, a field or any enterable object is outlined by a selection rectangle when it has the focus. You can hide this rectangle with this option. TRUE / FALSEinput, Write Pro, subform, list, list box
hideSystemHighlightbooleanThis property is added for selection type list boxes only. It is used to specify hiding highlighted records in the list box.TRUE / FALSElist box
labelsPlacementstringSpecifies the location of an object's displayed text."none", "top", "bottom", "left", "right"tab, progress indicators, ruler
layoutModestringSets the mode for displaying the 4D Write Pro document in the form area.  "embedded, "draft", "page"Write Pro
scrollbarHorizontalstringA tool allowing the user to move the viewing area to the left or right."visible", "hidden", "automatic"input, Write Pro, subform, list, listbox
scrollbarVerticalstringA tool allowing the user to move the viewing area up and down."visible", "hidden", "automatic"input, Write Pro, subform, list, listbox
showBackgroundbooleanDisplays/hides both background images and background color (displayed by default).TRUE / FALSEWrite Pro
showHeadersbooleanEnables or disactivates the visibility of the document or list box headers.TRUE / FALSEWrite Pro, list box
showHiddenCharsbooleanDisplays/hides invisible characters (hidden by default).TRUE / FALSEWrite Pro
showHorizontalRulerbooleanDisplays/hides the horizontal ruler (displayed by default). TRUE / FALSEWrite Pro
showVerticalRulerbooleanDisplays/hides the vertical ruler (displayed by default).TRUE / FALSEWrite Pro
showHTMLWysiwygbooleanEnables/disables the HTML WYSIWYG view, in which any 4D Write Pro advanced attributes which are not compliant with all browsers are removed (disabled by default). TRUE / FALSEWrite Pro
showFootersbooleanEnables or disactivates the visibility of the document or list box footers.TRUE / FALSEWrite Pro, list box
showPageFramesbooleanDisplays/hides the page frame when Page view mode is set to "Page". Default is hidden.TRUE / FALSEWrite Pro
showReferencesbooleanDisplays all inserted 4D expressions in the document as references.TRUE / FALSEWrite Pro
userInterfacestringDisplays/hides 4D View Pro user interface."ribbon", "toolbar", "none" (default value)View Pro
withFormulaBarbooleanDisplays/hides 4D View Pro formula bar. For use with the Toolbar interface only.TRUE / FALSE (default value)View Pro
zoomstringSets the zoom percentage for displaying 4D Write Pro area contents. Default is 100%.25, 50, 75, 100, 125, 150, 175, 200, 300, 400Write Pro

PropertyTypeDescriptionPossible ValuesObjects Supported
alternateFillcolorAllows setting a different background color for odd-numbered rows/columns in the list box. any css value; "transparent"; "automatic"list box, list box column
borderStylestringAllows setting a standard style for the object border. "system", "none", "solid", "dotted", "raised", "sunken", "double"text, input, web area, write, subform, plugin, splitter, buttonGrid, progress, ruler, spinner (Asynchronous progress bar), stepper, list, button, pictureButton, picturePopup, list box
fillcolorDefines the background color of an object.any css value; "transparent"; "automatic"text, rectangle, oval, input, list, list box
hideExtraBlankRowsbooleanDisactivates the visibility of extra, empty rows.TRUE / FALSElist box
rowFillSourcestringThe name of an array or expression to apply a custom background color to each row of the list box. RGB color valueslist box, list box column
strokeDashArraynumber array or stringDefines values for each line of an object. Ex. "6 1" or [6,1]variesline, rectangle, oval
strokeWidthintegerDesignates the thickness of a line.integer or 0 for smallest width on a printed formline, rectangle, oval
 

Print  

PropertyTypeDescriptionPossible ValuesObjects Supported
printFramestringHandles the print mode for objects whose size can vary from one record to another depending on their contents. "fixed", "fixedMultiple", "variable"subform, input, write

PropertyTypeDescriptionPossible ValuesObjects Supported
allowFontColorPickerbooleanAllows user modification of the object's font or color for the current session.TRUE / FALSEinput, list box
customBackgroundPicturepictureSets the picture that will be drawn in the background of the button.sandboxed absolute or relative path. Must be used in conjunction with the style property with the "custom" option.button, checkbox, radio
customBorderXintegerSets the size (in pixels) of the internal horizontal margins of an object. Must be used with the style property with the "custom" option.variesbutton, checkbox, radio
customBorderYintegerSets the size (in pixels) of the internal vertical margins of an object. Must be used with the style property with the "custom" option.variesbutton, checkbox, radio
customOffsetintegerSets a custom offset value in pixels. Must be used with the style property with the "custom" option.variesbutton, checkbox, radio
fontFamilystringName of font used in the object.variestext, groupBox, tab, input, button, checkbox, radio, dropdown, combo, progress, ruler, list, list box
fontSize integerFont size in points.minimum: 0text, groupBox, tab, input, button, checkbox, radio, dropdown, combo, progress, ruler, list, list box
fontStylestringSets the selected text to slant slightly to the right."normal", "italic"text, groupBox, tab, input, button, checkbox, radio, dropdown, combo, progress, ruler, list, list box
fontThemestringDesignates a style for the object's text."normal", "main", "additional"text, input
fontWeightstringSets the seleted text to appear darker and heavier."normal", "bold"text, groupBox, tab, input, button, checkbox, radio, dropdown, combo, progress, ruler, list, list box
metaSourcestringA meta object containing style and selection settings.Object expressionList box
rowStrokeSourcestringName of array or expression for managing row colors.varieslist box, list box column
rowStyleSourcestringName of array or expression for managing styles.varieslist box, list box column
storeDefaultStylebooleanStores the style tags with the text. Must be used with the multistyle property.TRUE / FALSEinput
strokecolorFont color used in the object.any css value, "transparent", "automatic"text, rectangle, oval, input, button, checkbox, radio, list, list box, list box column, lis tbox header, list box footer
styledTextbooleanApplies custom styles to dynamic text areas (fields or variables) in the Application environment. TRUE / FALSEinput
textAlignstringHorizontal location of text within the area that contains it."automatic", "right", "center", "justify", "left"text, groupBox, input, list box
textAnglestringModifies the orientation (rotation) of the text area.0, 90, 180, 270 text, input
textDecorationstringSets the selected text to have a line running beneath it."normal", "underline"text, groupBox, tab, input, button, checkbox, radio, dropdown, combo, progress, ruler, list, list box
verticalAlignstringVertical location of text within the area that contains it."automatic", "top", "middle", "bottom"list box, list box columns, list box header, list box footer
wordwrapstringManages the display of contents when it exceeds the width of the object."automatic" (excluding list box), "normal", "none"input, list box column, list box footer

The properties listed below are specific to the designated objects.

PropertyTypeDescriptionPossible ValuesObjects Supported
frameDelayintegerEnables cycling through the contents of the picture button at the specified speed (in ticks). minimum: 0pictureButton
loopBackToFirstFramebooleanPictures are displayed in a continuous loop. TRUE / FALSEpictureButton
switchBackWhenReleasedbooleanDisplays the first picture all the time except when the user clicks the button. Displays the second picture until the mouse button is released.TRUE / FALSEpictureButton
switchContinuouslybooleanAllows the user to hold down the mouse button to display the pictures continuously (i.e., as an animation). TRUE / FALSEpictureButton
switchWhenRolloverbooleanModifies the contents of the picture button when the mouse cursor passes over it. The initial picture is displayed when the cursor leaves the button’s area. TRUE / FALSEpictureButton
useLastFrameAsDisabledbooleanEnables setting the last thumbnail as the one to display when the button is disabled.TRUE / FALSEpictureButton

PropertyTypeDescriptionPossible ValuesObjects Supported
columnCountintegerSets the number of columns in a thumbnail table.minimum: 1buttonGrid, pictureButton, picturePopup
popupPlacementstringAllows displaying a symbol that appears as a triangle in the button, which indicates that there is a pop-up menu attached. "none", "linked", "separated"button
radioGroupstringEnables radio buttons to be used in coordinated sets: only one button at a time can be selected in the set. Radio group nameradio
rowCountintegerSets the number of rows in a thumbnail table.minimum: 1buttonGrid, pictureButton, picturePopup
stylestringAllows setting the general appearance of the button. See Button Style for more information."regular", "toolbar", "bevel", "roundedBevel", "gradientBevel", "texturedBevel", "office", "help", "circular", "disclosure", "roundedDisclosure", "custom","flat"button, checkbox, radio
textPlacementstringAllows modifying the relative location of the title in relation to the associated object. No effect if the object contains only a title (no associated picture) or a picture (no title). "left", "right", "top", "bottom", "center"button, checkbox, radio
threeStatebooleanAllows a check box object to accept a third state.TRUE / FALSEcheckbox

PropertyTypeDescriptionPossible ValuesObjects Supported
graduationStepintegerScale display measurement.variesprogress indicators, ruler
stepintegerMinimum interval accepted between values during use. For numeric steppers, this property represents seconds when the object is associated with a time type value and days when it is associated with a date type value.variesprogress indicators, ruler, stepper
showGraduationsbooleanDisplays/Hides the graduations next to the labels.TRUE / FALSEprogress indicators, ruler
Help  

PropertyTypeDescriptionPossible ValuesObjects Supported
tooltipstringProvide users with additional information about a field.variestab, input, button, checkbox, radio, dropdown, combo, splitter, buttonGrid, progress, ruler, spinner (Asynchronous progress bar), stepper, list, pictureButton, picturePopup, list box header, list box footer 

PropertyTypeDescriptionPossible ValuesObjects Supported
columnscolumn array Contains the attributes for the list box columns. varieslist box
highlightSetstringUsed to specify the set to be used to manage highlighted records in the list box (when the Arrays data source is selected, a Boolean array with the same name as the list box is used).varieslist box
lockedColumnCountintegerNumber of columns that must stay permanently displayed in the left part of the list box, even when the user scrolls through the columns horizontally.minimum: 0list box
staticColumnCountintegerNumber of columns that cannot be moved during execution.minimum: 0list box

PropertyTypeDescriptionPossible ValuesObjects Supported
horizontalLineStrokecolorDefines the color of the horizontal lines in a list box (gray by default). any css value, "'transparent", "automatic"list box
verticalLineStrokecolorDefines the color of the vertical lines in the a box (gray by default).any css value, "'transparent", "automatic"list box

PropertyTypeDescriptionPossible ValuesObjects Supported
footerobjectDesignates an object to be at the bottom and separate from the main body of the list box.varieslist box column
footerHeightstringUsed to set the row height for a list box footer. You can set the unit (lines or pixels) for the height value.pattern ^(\\d+)(px|em)?$ (positive decimal + px/em )list box
headerobjectDesignates an object to be at the top and separate from the main body of the list box.varieslist box column
headerHeightstringUsed to set the row height for a list box header. You can set the unit (lines or pixels) for the height value.pattern ^(\\d+)(px|em)?$ (positive decimal + px/em )list box
showFootersbooleanUsed to display or hide column or document footers.TRUE / FALSEwrite, list box
showHeadersboolean Used to display or hide column headers.TRUE / FALSEwrite, list box
Picture  

PropertyTypeDescriptionPossible ValuesObjects Supported
iconpictureThe name, number, or the pathname of the picture.sandboxed absolute or relative pathlist box header, button, checkbox
iconFramesintegerSets the exact number of states present in the picture.minimum: 1button, checkbox, radio
iconPlacementstringDesignates the placement of an icon in relation to the form object."none", "left", "right"list box header
Plugin  

PropertyTypeDescriptionPossible ValuesObjects Supported
pluginAreaKindstring Describes the type of plug-in.variesplugin 
customPropertiesstring/objectPlugin specific properties, passed to plugin as a JSON string if an object, or as a binary buffer if a base64 encoded stringvariesplugin

PropertyTypeDescriptionPossible ValuesObjects Supported
methodsAccessibilitystringInstantiates a special JavaScript object ($4d) to manage calls to 4D project methods.. Must be used with the webEngine property."all", "none"web area
progressSourcestringA value between 0 and 100, representing the page load completion percentage in the Web area. Automatically updated by 4D, cannot be modified manually. variesweb area
urlSourcestringDesignates the the URL loaded or being loading by the associated Web area.variesweb area
webEnginestringUsed to choose between two rendering engines for the Web area, depending on the specifics of the application."embedded", "system"web area

These properties store the page setup information for the form.

PropertyTypeDescriptionPossible ValuesObjects Supported
paperNamestringName of the paper definition"A4", "US Letter"...form 
paperWidthstringUsed if a paper named paperName was not found. Requires unit suffix: pt, in, mm, cm.ex: "210mm"form 
paperHeightstringUsed if a paper named paperName was not found. Requires unit suffix: pt, in, mm, cm.ex: "297mm"form 
orientationstringPaper orientation"landscape" (default is "portrait")form
scalenumberPage scaling percentage (100 means no scaling)minimum: 0form



See also 

Overview

 
PROPERTIES 

Product: 4D
Theme: Building forms

 
PAGE CONTENTS 
 
HISTORY 

Created: 4D v16 R6

 
ARTICLE USAGE

4D Design Reference ( 4D v19)