beautypg.com

2save the script, Figure 5-25. validate the zipcode function – Kofax INDICIUS 6.0 User Manual

Page 71

background image

Configuring Recognition

Getting Started Guide (Free-Form)

65

Function

MatchValue_Validate(sSearchName, sValue)

Const

RECIPIENT_ZIPCODE = "02111"

Select Case

sSearchName

Case

"Date"

'Insert Validation for search 'Date' here...

MatchValue_Validate

=

True

Case

"AccountNo"

'Insert Validation for search 'AccountNo' here...

MatchValue_Validate

=

True

Case

"TransferDate"

'Insert Validation for search 'TransferDate' here...

MatchValue_Validate

=

True

Case

"ZipCode"

'Ignore zip codes that are the recipients' zip codes

If

sValue = RECIPIENT_ZIPCODE

Then

MatchValue_Validate

=

False

Else

MatchValue_Validate

=

True

End If

'** Insert cases for new searches here **

Case Else

'This case catches any searches with Validation turned on but

'no case defined above.

MatchValue_Validate

=

True

End Select

End Function

Figure 5-25. Validate the ZipCode Function

2

Save the script.

X

To run the validate script

Now the validate script has been created, a property on the ZipCode search must be
set to run the validation prior to returning matches.

1

Move back to the image view by selecting the Image tab.

2

Select the ZipCode search from the drop down list at the top of the window.

3

On the Advanced panel under Scripts, change the value of the Run
Validation Script property to True.

X

To test the script with the formatting

1

Test the search.

The Search Results panel in the bottom left will show only validated
matches.