VBScript to cancel print if data contains a specific letter
using a scanner to enter data, I want check the data scanned and cancel printing if the data scanned has an "N" in the 22nd character; as in this entry FGB123001372:LKE4655JN677 and return an error message "Wrong Label Program"
I am new to VBScript, any help is appreciated.
0
-
Shotaro Ito
★ BarTender Hero ★
Create a text and link to text input box on a form.
On the text's Data source > Transform, apply VB Script below:
OnProcessData
If Mid(Value,22,1)="N" Then call Format.CancelPrinting("Wrong Label Program","")0 -
Thank you! this worked just as expected.
0
Bitte melden Sie sich an, um einen Kommentar zu hinterlassen.
Kommentare
2 Kommentare