Skip to main content
When processing semi-structured documents in ABBYY FlexiCapture, you will typically want to exclude documents that do not belong to the current type. One way to identify a document is to mark at least one element as required. In this particular case, the document heading will make a good identifier element, since it contains distinct text that can be easily read by the OCR engine.
An identifier element or set of elements can be described in a predefined Header element (not used in this sample).
The document heading will be used solely to identify the document as belonging to the given type and will not be recognized in ABBYY FlexiCapture. In the FlexiLayout, describe the document heading as an element of type Static Text:
  1. Click the FlexiLayout tab in the program main window.
  2. Select SearchElements in the FlexiLayout tree.
  3. Select the Static Text command in FlexiLayout → Add Elements → Static Text or in the shortcut menu of the element.
  4. In the Name field, type a name for the element, for example, FormHeader.
  5. Select Required element on the General tab, because the document heading is a required element.
    Screenshot of the General tab of the Properties of SearchElements.StaticText dialog box in ABBYY FlexiLayout Studio, showing the FormHeader element marked as a Required element in the Search control group.
  6. Click the Static Text tab.
    Screenshot of the Static Text tab of the Properties of SearchElements.StaticText dialog box in ABBYY FlexiLayout Studio, showing the Search text field with the two recipe headings and Max error percentage set to 20.
  7. In the Search text field, type the text to find.
    The batch contains test documents that have different headings: Easiest Recipes or Easy to Cook Recipes. Enter both headings.
    The headings are written in one line on all the test images. Therefore, you can type the headings without spaces to speed up the search for single-line static text. Separate the two alternative headings by ”|”.
  8. Set the maximum number of errors that the detected text may contain (either in percentage points or as a number). In this particular case, set the Max error percentage to 20, which allows 5 errors among the 25 characters of the document heading.
The maximum number of errors is selected by trial and error.