Additions attacher - Demonstration

The error labels and bubble tooltips are added to all leaf items by specifying an AdditionsAttacher.

Address
Street
100
House Number
10
Flat Number
10
Post Code
Post
50
City
50
XML output

        
Additions attacher - Description

It is a common issue to add some extra functionality to a set of MForm items.

In two of the already considered examples, the Bubble tooltip addition and the Error Label addition controls were attached to all of the leaf items.

In order to limit the amount of code and to avoid repetetiveness, the AdditionsAttacher modifier can be used. Instead of defining additions near each and every field, one AdditionsAttacher can be added to the Root control.

Properties

The AdditionsAttacher has the following properties:

  • SelectorPath - the path to all child items that should have the additions added
  • Filter - the filter to select only items of the selected type

Besides that, the AdditionsAttacher contains an inner property AdditionalsTemplate

In this property many Addition controls can be defined - all of them will be added to the items selected using the SelectorPath and Filter.