Validating the line item totals

Due to the way Datacap processes line item grids, you cannot attach calculations to line item objects. Instead, what you can do is create a field for calculation purposes.

About this task

You used the CalculateFields action earlier when you checked that the total cost of the air ticket equals the airfare plus taxes.
Library Action Description
Validations CalculateFields Returns True if the arithmetic expression is valid; returns False otherwise.

Previously, you used the action to complete the calculation at the page level because the page was the next level up in the document hierarchy. In this case, the next level up in the hierarchy is the line item.

Because of the manner in which Datacap processes line item grids, you cannot attach calculations to line item objects. Instead, you can create a field for calculation purposes, for example, Validation, within the line item and attach the rule to this field.