2.2.63 errorCondition

The errorCondition element specifies a custom validation for a set of XML nodes in the form file.

Parent Elements

customValidation

Child Elements

errorMessage

Attributes:

expression: This attribute specifies an XPath expression to validate the XML nodes returned by evaluating the match attribute value. If the expressionContext attribute is present, it specifies a context for the XPath expression.

expressionContext: This attribute specifies the XML node that provides the root context for the expression attribute value. If this attribute is not present, its value MUST be interpreted as an empty string.

match: This attribute specifies an XPath expression that evaluates to the XML nodes for which the custom validation applies.

showErrorOn: This attribute specifies the XML nodes on which the error MUST be displayed when the form is filled out. If this attribute is not present, its value MUST be interpreted as ".".

The following W3C XML Schema ([XMLSCHEMA1] section 2.1) fragment specifies the contents of this element.

 <xsd:element name="errorCondition">
   <xsd:complexType>
     <xsd:sequence>
       <xsd:element ref="xsf:errorMessage"/>
     </xsd:sequence>
     <xsd:attribute name="match" type="xsd:string" use="required"/>
     <xsd:attribute name="expression" type="xsd:string" use="required"/>
     <xsd:attribute name="expressionContext" type="xsd:string" use="optional"/>
     <xsd:attribute name="showErrorOn" type="xsd:string" use="optional"/>
   </xsd:complexType>
 </xsd:element>