Skip to main content
Version: Classic

Data


Purpose and use

This document function can be used to transfer properties via the
primedocs Connect interface (Structure ) by defining a schema using this function.


Basic structure

<DataConfiguration>
<Schema>
<Text Id="MyTestValue" />

<Object Id="TestObject">
<Schema>
<Text Id="TestValueInTestObject" />
</Schema>
</Object>

<ObjectCollection Id="TestObjectCollection">
<Schema>
<Text Id="TestValueInTestObjectCollection" />
</Schema>
</ObjectCollection>
</Schema>
<!-- Optional:
<GlobalSchema Key="GlobalKey" />
-->
</DataConfiguration>

Schema / GlobalSchema

This function uses the schema element to define which data can be transmitted via the interface.
The elements defined here can then be stored in the respective template. The schema can also be stored at Global Configurations via <GlobalSchema Key="..." />.

The Schema or GlobalSchema can then define these types:

Text

Texts can be received via the Text-element.

Attribute nameDescription
Id
(required)
Is required for identification. Must not contain spaces and must be unique.

FormattedText

ℹ️ Info This feature is available starting with version 4.0.30107.0.

The FormattedText-element can be used to receive text with simple formatting options.

Attribute nameDescription
Id
(required)
Is required for identification. Must not contain spaces and must be unique.
note

The data can be transmitted in various formats (Html or HtmlBase64).

WordContent

ℹ️ Info This feature is available starting with version 4.0.30107.0.

The WordContent-element can be used to receive texts with Word-specific formatting options.

Attribute nameDescription
Id
(required)
Is required for identification. Must not contain spaces and must be unique.
note

The data can be transmitted in various formats (DocxBase64, FlatOpc or FlatOpcBase64).

Object

If you want to group several elements, an element of the Object type is suitable. Text-, FormattedText- or WordContent-elements can then be found below the Object.

Attribute nameDescription
Id
(required)
Is required for identification. Must not contain spaces and must be unique.
Required
(optional)
If true: The object must be transmitted.

:::note
> Objects configured with Required="true" can be used directly as fields in the template.
warning

If an Object with Required="true" is not transmitted, this is considered an error and document generation is aborted.

ObjectCollection

If you want to receive a list of data, use the ObjectCollection element, which in turn contains Text-, FormattedText- or WordContent-elements.

Attribute nameDescription
Id
(required)
Is required for identification. Must not contain spaces and must be unique.