Placeholder Mapping
Purpose and use
Placeholders are required so that dynamic data can be displayed in layouts.
Defined placeholders, configured via the Placeholder Definition function on a parent template, such as a layout or a master template, can be provided with the respective data via this function. The data can be generated from Forms or via the Fields function.
Basic structure
<PlaceholderMappingConfiguration>
<Mappings>
<!-- Placeholders -->
</Mappings>
</PlaceholderDefinitionConfiguration>
Attributes
The following attributes must be set for all available element types (Text, Picture):
Attribute name | Description |
---|---|
| Is required for identification, can be named the same as the field from Forms or Fields. Must not contain any spaces and must be unique. |
| Is required to map the field from Forms or Fields. Accordingly, the ID of the corresponding field is entered here. |
There are three sources for placeholders that can be addressed in the SourceField
attribute:
a user field:
Profile.User.FirstName
a Forms field:
Forms.MyTextfield
/Forms.MainSigner.FirstName
a field:
MyField
(Caution: the field’s name cannot contain a dot since grouping is only possible in Objects and ObjectCollections).
In the vast majority of cases, a Field is created that dynamically combines and returns content. It is then assigned to a placeholder. User fields are practically never assigned without a detour via a Field.
Elements
Text
<Text Name="CreateDate" SourceField="Forms.Date" />
Picture
<Picture Name="PartnerLogo" SourceField="PartnerLogo" />
GlobalMappings
The GlobalMappings
element can be used to retrieve a globally stored placeholder mapping.
More information about the global configurations can be found here: Global Configurations | Working with typed fields.
A concrete example for recognizing the connection between the global entry and the reference to a global entry can be found here: Global Configurations | Referencing global entries in the templates.
Attributes for GlobalMappings
The reference to a global entry is made using the Key
attribute. If you select it, a list of all available global entries is automatically displayed.
Attribute name | Description |
---|---|
| The ID of the global entry to be referenced. |
Example XML configuration
Â
PrimeSoft AG, Bahnhofstrasse 4, 8360 Eschlikon, Switzerland