SAMPLE
Applies To:
ITScriptNet V1/V2
The samples shows how you can compare two barcodes to determine if they contain the same data. By using the After Validation... script the scrpt can use the ValidationFail function to prevent the user from continuing if the barcodes do not match.
This validation technique is often used to ensure the user has not mistakenly scanned an unexpected barcode without realizing the mistake.
DETAILS
The following code is placed in the After Validation... script of the MatchBarcode Prompt.
MATCHBARCODE PROMPT: AFTER VALIDATION SCRIPT
;COMPARE BARCODES
IF($Barcode$ = $MatchBarcode$)
;NOTIFY THE USER OF A MATCH
FlashLEDS()
Beep()
Beep()
Beep()
ELSE
;USE VALIDATIONFAIL TO NOTIFY USER OF A MIS-MATCH
ValidationFail("Barcodes do NOT Match!")
ENDIF
- If the barcodes MATCH, the terminal's LEDs will flash and it will Beep three times (On supported Terminals).
- If the barcodes DO NOT MATCH, the terminal will display the ValidationFail message and not allow the user to continue to the next prompt.
This article last updated:
1/1/2009 12:00:00 AM