Sample 3. Step 5: Detecting the name of the Delivery Address field with a kwDeliveryAddress element
Analysis of the test images reveals that the string "DeliveryAddress" may be used as the keywords for the Delivery Address field name. Set the maximum percentage of errors to 20 per cent, i.e. in case of 15 letters string mean no more than 3 errors in the entire string.
Note.The case of the letters does not affect the search and is only used to make the text more readable. The maximum number of errors is determined by method of trial and error. For more information about the parameters of a Static Text element, see Help/Elements/Element Properties/ Static Text.
To create the kwDeliveryAddress element:
- In the InvoiceHeader element, create an element of type Static Text and name it kwDeliveryAddress.
- Click the Static Text tab.
- In the Search text field, enter the text to find: "DeliveryAddress".
- Set the Max error percentage to 20.
- Click the Advanced tab.
- Since the Delivery Address field is in the upper third and in the left third of the image, set the following additional search constraint in the Advanced pre-search relations field: Look for the object in the left third of the image. Look for the object in the upper third of the image. In the FlexiLayout language:
Above: PageRect.Top + PageRect.Height/3;
LeftOf: PageRect.Left + PageRect.Width/3; - Try matching the FlexiLayout with the test images and make sure that the program successfully detects the element on all the images where applicable.
Note.To match the FlexiLayout with all the test images, you can use the shortcut keys:
- Activate the Batch window
- Press Ctrl+A for Select All pages
- Press Ctrl+E for Match FlexiLayout
4/12/2024 6:16:02 PM