Fallback Value / Binding
A binding is the connection between a data source and a consumer. The data source is specified using binding notation (see Syntax of binding strings). Bindings can be defined in various places in Intrexx. Depending on this, they are also entered at various points in the XML. Bindings can be used as follows:
Set a binding as the default (e.g., for input fields)
For input fields, you can define a data field binding as the default for new records on the "Binding" tab of the Properties dialog box.
Specify the desired control type and display value here.
Default for new records / For existing records
Default values are used when the binding does not return a value for new or existing records. Click "Edit Default Value"
to define a new default value.
Select the desired binding here and click "OK."
"Apply Default Value" applies the defined default value.
Here is the corresponding XML, which you can access by pressing F4 in the highlighted input field when Expert Options are enabled:
<textcontrol guid="5758A9C9EC60A724AC85B3CAE8F2EA28B23EFE45" name="textcontrol30057DD4" inputlength="255" label="false" readonly="false" rect="100,45,250,20" required="false" source="container['7338AC8FD8B5B5C39DBB2AD2F456529DD84A233A'].dataField['D6F55F095F2E5A5570EAB98A8773B0E2F193FBA1']">
<property>
<title de="Titel" en="Title"/>
</property>
<defaultvalue record="new" source="container['7338AC8FD8B5B5C39DBB2AD2F456529DD84A233A'].dataField['8860BBDFB02E3E9E43940D63A4A64A0AACAEF2DC']" sourceType="binding"/>
</textcontrol>
Data field
Container
Select the container here that contains the data field whose value you want to use as the fallback value.
Data field
Select the desired data field here.
Select a data field from a parent data group
Opens a dialog box in which a data field can be selected from a parent data group, if applicable.
Session / Request / Processing Context
Enter the name of the request parameter, session variable, or processing context variable in the appropriate field here.
Static value
Enter a static value here. Any string can be used, as long as it matches the required data type. For example, if an integer value is required, "123" can be passed, but not "ABC".
For checkboxes, you can enable or disable the "Selected" setting as a static value here, depending on whether you want the checkbox to be selected or not when the page loads in the browser.
With the "Multiple Selection 2.0" element, it is also possible to specify multiple static values here—separated by a double pipe.
Velocity
You can enter a Velocity script here to provide the fallback value. Velocity can only be used in a limited way with page parameters. Objects such as $DC and $drRecord are not available at this point; if/else constructs can be used.
New GUID
This option automatically generates a GUID that is used as a fallback value.
Language
For the language, you can choose between "Portal Default Language" and "Context-Dependent Language." The context-sensitive language is defined by the chain
- rq_lang/cookie_lang
- Default language of the logged-in user
- Portal's default language
Current User
Here, you can select a data field from the "Users" module.
System Data Group
Application
Select the application here that contains the desired system data group.
Data field
Select the data field here.
Parameters
Select the desired parameter here for which you want to use the fallback values. All parameters on the current page are available for selection.
Parameters (Application API)
In the API environment, API parameters can be selected for comparison. You can find instructions on how to do this here.
Date & Time
If a data field with the control type "Date & Time," "Date," or "Time" is selected as the display value, the date can be adjusted here. You can find all the information about the settings here.
Automatic Increase
If a data field with the "Integer" control type is selected, this option can be used to set up a counter. When a new data record is created, the most recently entered value is automatically incremented by 1. This new value is used as the default.
Tree
This option is available only for jumps within the "Tree View" element.
Value of the current tree node
You can select the primary key, the node ID, the parent node ID, or the title of the current tree node as the value. The "Node ID" value is a comma-separated value consisting of the key, the parent key, and the sort order. The "Parent Node ID" value corresponds to the parent key. The "Title" value is the title of the current node.
Date
This option is available only for calendar plugins. You can select any of the data items defined in the plugin properties on the "General" tab.
Resource
This option is available only for calendar plugins if the "Enable resource display" setting is selected on the "Options" tab. You can choose from the data fields that are selected on the "Options" tab as a title field, sort field, grouping field, or image.
Resource
Select the desired resource data field here.
Current Data Set
This option is available only if no ReadContainer is supported, such as in processes.
Data field
Select the desired data field here.
More
Under the "More" option, you'll find a drop-down list of binding types to which you can assign values.
Persistently store data per user using "appUserProfile"
You can find all additional information here.
Bindings
Syntax of Binding Strings
bindingType
bindingType['guid|name']
bindingType["guid|name"]
bindingType.guid
bindingType.name
bindingType['guid|name'].guid
bindingType["guid|name"].name
bindingType['guid|name'].subtype['guid|name']
bindingType["guid|name"].subtype["guid|name"]
bindingType["guid|name"].subtype["guid|name"].name
...
Not all bindings are available in every context.
compatibility.primaryKey compatibility.primaryKey['name'] compatibility.foreignKey compatibility.foreignKey['name'] compatibility.primaryOrForeignKey compatibility.primaryOrForeignKey['name']
container
Returns the value of a Read or WriteContainer. This binding can be defined using the "Data Field" option. It can also be entered as a value for the "Other" option using the following syntax:
container['GUID|NAME'].dataField['GUID|NAME']
container['GUID|NAME'].member['GUID|NAME']
container['GUID|NAME'].recordOwner (The value of record owner field)
container['GUID|NAME'].userId (The value of userid field)
container['GUID|NAME'].key (The value of the single primary key)
container['GUID|NAME'].primaryKey (The value of the single primary key)
container['GUID|NAME'].key['GUID|NAME'] (The value of the primary key with the GUID or name)
container['GUID|NAME'].primaryKey['GUID|NAME'] (The value of the primary key with the GUID or name)
container['GUID|NAME'].foreignKey['GUID|NAME'] (The value of the foreign key with the GUID or name)
container['GUID|NAME'].foreignKey (The value of the single foreign key)
container['GUID|NAME'].combinedKey (The value of the single primary key or a formated Key string like "LID= 1, LANG= de")
container['GUID|NAME'].combinedPrimaryKey (The value of the single primary key or a formated Key string like "LID= 1, LANG= de")
container['GUID|NAME'].combinedForeignKey (The value of the single foreign key or a formated Key string like "LID= 1, LANG= de")
control
Returns the value of a check. This binding can be entered as the value for the "Other" option using the following syntax:
control['GUID']
control['NAME']
control.guid['CONTROLGUID']
control.name['CONTROLNAME']
control.sysIdent['SYSIDENT']
currentDate
Returns the current date without the time.
currentDate currentDate['Y,M,D'] currentDate[+1,2,-3] Adjust current date: Year +1, month = 2, day -3 Y=(|[+-]?\d+) M=(|[+-]?\d+) D=(|[+-]?\d+)
Rule definition: See p_adjust in de.uplanet.util.CalendarUtil.modifyCalendar(T, String p_adjust, boolean)
currentDatetime
Returns the current date and time.
currentDatetime
currentDatetime.%TIMEZONE%
currentDatetime['Y,M,D,H,m,S']
currentDatetime[+1,2,-3,2, +2, 0] Adjust current date: Year +1, month = 2, day -3, hour=3,min+2,sec=0
Y=(|[+-]?\d+)
M=(|[+-]?\d+)
D=(|[+-]?\d+)
H=(|[+-]?\d+)
m=(|[+-]?\d+)
S=(|[+-]?\d+)
currentDatetime['Y,M,D,H,m,S'].%TIMEZONE%
Rule definition: See p_adjust in de.uplanet.util.CalendarUtil.modifyCalendar(T, String p_adjust, boolean)
%TIMEZONE% must be a valid time zone ID (such as UTC).
currentTime
Returns the current time.
currentTime currentTime['H,m,S'] currentTime[+1,2,-3] Adjust current date: Hour +1, minute = 2, second -3 H=(|[+-]?\d+) m=(|[+-]?\d+) S=(|[+-]?\d+)
Rule definition: See p_adjust in de.uplanet.util.CalendarUtil.modifyCalendar(T, String p_adjust, boolean)
currentUser
Returns the current user.
currentUser[FIELDGUID|NAME]
Replace "NAME" with the bean name.
recId
Returns a value from "old" rq_RecId or qs_RecId arguments in the following format: "LID= 1; LANG= de". This binding is used for compatibility reasons and should not be written by the user.
recId['LID'](gets the LID value out of the rec id string )
recId['LANG'](gets the LANG value out of the rec id string )
request
This binding can be defined using the "Request" option. It can also be entered as a value for the "Other" option using the following syntax:
request['name']
sharedState
This binding can be defined using the "Processing Context" option. It can also be entered as a value for the "Other" option using the following syntax:
sharedState['name']
session
This binding can be defined using the "Session" option. It can also be entered as a value for the "Other" option using the following syntax:
session['variable name']
staticText
Returns static text.
staticText['TEXT'] => TEXT will be returned
systemDataGroup
Returns the value of a data field from a system data group in the current application or a specific application.
systemDataGroup['APP_GUID'].dataField['FIELD_GUID']
target.argument, parameter
Returns a parameter value. target.argument[''] can be defined using the "Parameter" option. If a binding is created using the "Advanced" option, "parameter['']" is generally preferred, as this notation is more intuitive and the keyword "parameter" is also used in Velocity and Groovy.
parameter['NAME']
target.argument['NAME']
uniqueId
Generates a random number.
uniqueId
uniqueGuid
Generates a GUID.
uniqueGuid
velocity
Returns the Velocity text of the binding. The goal is to interpret the text. This binding can be entered as the value for the "Velocity" option using the following syntax:
velocity['TEXT'] => The interpreted velocity TEXT will be returned
defaultLanguage
Returns the portal's default language (corresponds to $defaultLanguagein Velocity).
contextLanguage
Returns the current portal language (equivalent to "$lang" in Velocity)
appUserProfile
appUserProfile['key']
Returns a value from the UserProfile. You can find more information here.
Resolve value
Timing for the settlement of the value
If possible, you can configure here whether the value should be resolved when the current page loads or when the target page loads.
Binding type "appUserProfile"
This binding type allows you to store data on a per-user basis. You can store information for the current user in any value and retrieve it at any time, for example, as a default value in input fields.
"AppUserProfile" can be used in a similar way to a system data group —only it is user-specific. This way, you can, for example, control views based on the user. In principle, it works like a shared state or a session variable, except that the data is available persistently.
Delimitation
The "appUserProfile" binding type expands the possibilities for storing and processing any information specific to a user.
| Method | User-dependent | Availability |
| SharedState / Processing Context | No | The value remains in effect until a new value is set. |
| Session variable | Yes | The value is available within a session. |
| Request Value / Parameter | No | The value is available for an action. |
| System Data Group | No | The value is permanently available within an application. |
| appUserProfile | Yes | The value remains in effect until the user sets a new value. |
"No-code" Implementation
If the value is defined and saved on the input pages, the binding can be used without any programming.
The binding can be defined on input pages when creating a WriteContainer. The custom class "AppUserProfile" is available there.
The control that defines the values is added to this WriteContainer. The target is defined in the binding's properties.
The value can then be set as the default for a control. To do this, select the "appUserProfile" binding type under "More" and enter the defined value.
"Low-Code" Implementation
If no write container is available for the definition in which the binding type “appUserProfile” can be defined, it can also be set using Velocity and Groovy. You can find all the information you need for using this in Groovy or Velocity scripts here:
More Information
Parameters - An Overview
Create Parameters, Fallback Values, and Semantic Values
























