IBM Datacap, Version 8.1            

Removing non-line items from the page data file

The region that is defined for the line item grid might include fields that are not line items; for example, the Total field in the previous example. Therefore, Taskmaster might create line items for items that are not actually line items.

In the following example, although there are only two line items on the invoice, Taskmaster created a third line item for the Total field.

Image of an invoice that lists two items and the total cost.
<P id="TM000001">
<F id="Grid_region">
       <F id="Line_item0">     <--First line item
          <F id="Item"> etc.</F>         <--Has the value "1176"
          <F id="Description"> etc.</F>  <--Has the value "Widget"
          <F id="Cost"> etc.</F>         <--Has the value "6.95"
       </F>
       <F id="Line_item1">     <--Second line item
          <F id="Item"> etc.</F>         <--Has the value "9122"
          <F id="Description"> etc.</F>  <--Has the value "Widget"
          <F id="Cost"> etc.</F>         <--Has the value "8.25"
       </F>
       <F id="Line_item2">     <--Third line item (not a line item)
          <F id="Item"> etc.</F>         <--No data
          <F id="Description"> etc.</F>  <--Has the value "Total"
          <F id="Cost"> etc.</F>         <--Has the value "15.20"
       </F>
       etc.
  1. If the page you are processing has non-line item fields within the grid region, you might need to identify those non-line items and remove them. Taskmaster includes an action to identify and remove these items for you.
    Library Action Description
    Validations CheckSubFields Confirms that values exist in child fields of specified parent field. Deletes the parent field if any of the specified child fields have no values.
  2. You must attach the rule to the line item grid object in the document hierarchy and ensure that the rule runs after recognition is complete. Use one of the following methods to attach the rule:
    • Include the rule in the Recognize ruleset and attach it to the line item grid object's Close element.
    • Include the rule within a separate task profile that runs after recognition but before validation; for example, the Clean ruleset. Attach it to the line item grid object's Openelement.

    When you use either method, Taskmaster recognizes that the Item field in the third line item has no value. Therefore, Taskmaster deletes the field, leaving only the two real line items.



Feedback

Last updated: November 2013
dcadg406.htm

© Copyright IBM Corporation 2013.