CommandsSystem configuration
^CV - Code Validation
Enables or disables barcode data validation
^CV - Code Validation
Overview
The ^CV command acts as a switch to turn code validation ON and OFF for bar codes. When enabled, all bar code data is checked for errors including invalid characters, incorrect check digits, data field length issues, and parameter problems. Invalid data results in an error message printed in reverse image in place of the bar code.
Syntax
^CVaParameters
- a = Code Validation setting
- Y = Yes, enable validation
- N = No, disable validation (default)
Description
- Validates barcode data for errors
- Checks for invalid characters in barcode set
- Verifies check digits when applicable
- Validates data field length
- Detects parameter errors
- Displays error codes when validation fails
Error Codes
| Code | Description |
|---|---|
| C | Character not in set |
| E | Check digit incorrect |
| L | Data too long |
| S | Data too short |
| P | Parameter error |
Usage Notes
- Once enabled, remains active until disabled or printer powers off
- Setting is not permanently saved (resets on power cycle)
- If multiple errors exist, only first detected error is displayed
- Only affects barcodes; not applicable to text fields
- Invalid barcodes displayed in reverse image (white on black)
Examples
Enable Code Validation
^CVYDisable Code Validation
^CVNError Display
When validation detects an error, instead of printing the barcode, the printer displays the barcode's first letter and error code in reverse image:
^XA
^CVY
^FO50,50
^BC
^FD1234567890^FS
^XZRelated Commands
^BC- Code 128 Barcode^B3- Code 39 Barcode^FD- Field Data^BY- Narrow Bar Width