Skip to main content

Perform multistage validation using document variants and activity variants

Article # 3038119 - Page views: 101


How can document variants and activity variants be used to perform multistage Validation?



Using the Capture Starter Pack shipped with KTA, I created a 2-step validation process as shown below.  The Validation1 activity would be used to validate all simple fields in the document.  The Validation2 activity would be used to validate the table field in the document.  


Note:  To change the document variant of a document, the CaptureDocumentService.UpdateDocumentVariant() method must be called prior to Validation.  If the document doesn't have the correct document variant set, the associated activity variants won't be used.

This was achieved using a document variant and 2 activity variants for the Northwest document type.


The NorthwestVariant document variant is configured to ignore no fields in this document class.

The Nw_ValidateSimpleFields activity variant is configured to Ignore and Mask the table field and columns.  See below.

The Nw_ValidateTableFields activity variant is configured to Ignore and Mask the simple fields.See below.


In the take activity form associated with Validation1, the Nw_ValidateSimpleFields activity variant was mapped to the validation control.


In the take activity form associated with Validation2, the Nw_ValidateTableFields activity variant was mapped to the validation control.  


At runtime, in Validation1 we see the below.  The table field is not shown in the document form as we choose to Ignore this in the activity variant.  In addition, the table data is "blacked out" in the document viewer as we choose to Mask this in the activity variant.


We can validate the displayed fields and complete the activity even if the table field has invalid data.  In Validation2, we see the below.  Only the table field is shown with all other fields being ignored and masked.


Level of Complexity 



Applies to  

Product Version Build Environment Hardware
KTA ALL      


Add any references to other internal or external articles


Article # 3038119
  • Was this article helpful?