Skip to main content
Before you can map ABBYY FlexiCapture Document Definition fields to M-Files property definitions, configure the metadata structure in M-Files Admin on your M-Files server.

Configure the metadata structure for the main document

1

Create a class for the main document

In the built-in Document object type, or in your custom object type, create a class for the main document, such as Invoice. This class represents the type of documents you work with.
Screenshot of M-Files Admin showing a new class created under the built-in Document object type to represent the main document, such as an Invoice.
2

Add property definitions for the metadata fields

In the class properties, create and add the property definitions that represent your metadata fields. One of these fields must be a Set as name field, which is used to set the document’s name.
3

Allow searching by the name property

If you are not using the built-in Set as name property Name or title, select the Allow searching for objects by this property option on the General tab.

Configure the metadata structure for LineItems

1

Create an object type for one line

Create an object type that represents one line in LineItems. M-Files automatically creates a property definition with the same name, which lets you link objects of this type to the main document object.This class represents the LineItems data, so add a property definition to it for each table column in the ABBYY FlexiCapture Document Definition.
The object type you create for LineItems must have only one class.
Screenshot of the Class Properties dialog box for the LineItem class in M-Files Admin, showing its property definitions with data types, the Set As Name button, and the asterisk marking the property used as the object name.
To name the objects in this class, use one of the following ways:
  • Select a property definition on the template that must always be filled in.
  • Create a property definition with an automatic value and define it as the name of the objects. On the Automatic Values tab of the Property Definition dialog box, select Set As Name.
For a clearer representation of the data, use the Simple concatenating of properties option for the Automatic value, and add the required properties of the LineItems class to the placeholders.
2

Link the main document to its line items

In the class you created for the main document, create a property definition of the Choose from list (multi-select) data type. This links one Invoice object to multiple Line Item objects, so it must show values from the list of LineItem object types.You can use the property definition that M-Files created automatically when you added the LineItem object type.
Screenshot of M-Files Admin showing a Choose from list (multi-select) property definition in the main document class that links one Invoice object to multiple Line Item objects.

Map Line Items in the export settings

When you map Line Items in the script or in the XML file, specify the property definition for the LineItems name in the main document, followed by the property definition in the class created for Line Items.
Screenshot of the FlexiCapture Demo Vault metadata structure tree in M-Files Admin, with the LineItem property highlighted in the European Invoice class and the Article number property highlighted in the LineItem class, shown next to the matching script and XML mapping examples.
In a script, use the following format:
In an XML configuration file, use the following format:
In both examples, Invoice Layout\LineItems\ArticleNumber is the full field path in the ABBYY FlexiCapture Document Definition. LineItem\Article number names the property definition in the main document class, followed by the property definition in the LineItem class.

Match the field data types

The data type of each ABBYY FlexiCapture Document Definition field must be identical in nature to its chosen M-Files counterpart. The following correspondences are recommended: