Understanding Subform Design-Time Considerations

This list describes many of the conditions and factors that you should take into account while designing the subform in FDA:

  • Subforms have their own BVs (only one per subform), grids, and filters that pass logic between other subforms.

  • Subforms can be used as tab pages, or they can be placed on a tab page.

  • Multiple tab controls are permitted unless the subform is inside a tab page.

    If the subform is inside a tab page, it cannot have tab controls. However, this restriction cannot be enforced programmatically when you reuse subforms. Therefore, when developing reusable subforms, carefully consider the context in which you expect to use them to prevent poor user interface design.

  • Toolbar and form/row exits are not permitted on a subform.

  • Subforms do not contain scroll bars; you must display all controls within the form.

  • You can add action buttons (Cancel, OK, and so forth) to a subform.

    No default action buttons are defined by FDA. Default actions can be placed anywhere on the subform. For example, the default action, Save, can be placed beneath the grid. Use the dotted lines at the top and bottom of a subform during design time as guides for where to place more common default actions. For example, buttons such as Select or Find belong at the top of the form while buttons such as Save or Cancel belong at the bottom.

  • You can define ER that fires when the user sets or removes focus from the subform, using the Enter Focus and Leave Focus subform events.

After designing the subform, you must return to the parent form and map the parent data fields to the child so that the two can share data as you intend. After associating a data structure with the parent, use the Mapping Links property to establish the data mapping between the parent and subform.

Note: Because subforms can act as parents, they have the Mapping Links property. However, you can only create mappings on the parent level. If you cannot find the child subform in the Link To field, then you might have mistakenly entered the data mapping property for the child instead of the parent.

These property values are significant for subforms:

  • Show Subform Header

    This property enables you to hide or show the title bar of the subform. You must show the header if you want to make the subform collapsible (with the Collapsable property).

  • Collapsable

    This property determines whether the user can choose to view just the title bar (header) of the subform. The ability to collapse subforms is useful on forms that contain a large number of subforms. You must show the header (with the Show Header property) if you want to make the subform collapsible.

  • Transaction

    This property determines where the subform falls within the transaction boundary for the form as a whole.

Additionally, subforms support the form-level properties: Update on Businessview and Fetch on Businessview.

Finally, to enhance reuse, you can associate any number of functions with a subform at design time. Then, during runtime, the parent of the subform can invoke any of those functions with the Call Function system function.