GROUP item type

Defines a layout area to group other layout elements together.

GROUP item basics

A GROUP form item type groups other form items together, typically in a groupbox widget.

Defining an GROUP

The GROUP form item typically gets a TEXT attribute, to define the title of the group. Consider using localized strings for this attribute:
Note: Depending on the front-end platform, a GROUP container may get a border, and a title. The border may also be rendered with a shadow effect.
Consider identifying group elements with a name, in order to manipulate the group during program execution. For example use the ui.Form.setElementHidden() method to hide or show groups in a form:
GROUP g1: g_cust_info, ... ;   -- grid-based layout
GROUP g_cust_info, ... ;       -- stack-based layout

Front-ends support different presentation and behavior options, which can be controlled by a STYLE attribute. For more details, see Style attributes common to all elements and Group style attributes.

Groups in grid-based layout

In a LAYOUT tree with GROUP containers, if you want to include several children in a GROUP, you can add a VBOX or HBOX into the GROUP, to define how these form items are aligned.

Note: When defining a GROUP container, you cannot set the GRIDCHILDRENINPARENT attribute. This attribute makes sense only for a group item defined with a layout tag contained in a GRID area.
Consider using a group layout tag inside a GRID container, this layout specification technique is often more appropriate to define forms:
<G g1             ><G g2        >
[l1  :f1          ][f4          ]
<G g3                            >

Groups in stack-based layout

In a STACK container, GROUP form items are one of the base concepts used to put stack items together. For more details see Stacked group rendering.

Collapsible groups

By default, groups are not collapsible.

Some front-ends (see Group presentation style attributes reference) support the collapsible presentation style attribute, to let end users expand/collapse GROUP elements in your forms.

Note: This feature is only available with the GBC front-end.

When a group is defined as collapsible, the collapserPosition style attribute can be used to define the position of the collapser icon.

The initiallyCollapsed style attribute defines if the collapsible group is collapsed or expanded when the form is displayed. Values can be "yes", "no", "never" and "always".

For example:
<Style name="Group.mystyle">
   <StyleAttribute name="collapsible" value="yes" />
   <StyleAttribute name="collapserPosition" value="right" />
   <StyleAttribute name="initiallyCollapsed" value="yes" />
Note: These style attributes are supported in both stack and grid layout.

For more details, see Group style attributes.

Groups on mobile devices

On mobile devices, groups render depending on the platform standards:
  • With GMA/Androidâ„¢, groups are visualized by a simple separator under the group title. Complex layout construction is supported: groups in groups, groups in a grid, and so on.
  • With GMI/iOS, the layout is limited by the platform GUI standards. The only visible grouping container element is a group. Groups within groups are not allowed. GMI enforces each form item as a member in a group. There can be group headers and footers, but no elements in between groups.

Where to use a GROUP

A GROUP form item can be defined in different ways:
  1. As a GROUP container in a LAYOUT tree, within a grid-based layout.
  2. As a <GROUP > layout tag with a GROUP item definition in the ATTRIBUTES section, within a grid-based layout.
  3. As a GROUP stack item, inside a STACK container, within a stack-based layout.