I'm testing a string to see if it matches code39 character set, described by sPattern, below.
The following code works on another textbox BeforeUpdate event, but is producing an error on a different textbox's BeforeUpdate event.
Me.VendorItemNumber contains a conforming value.
There IS a reason... Though I'm not finding it.
I'd appreciate your ideas...
Many Thanks, Jacob
'Does the VIN conform to code39?
sPattern = "*[!0-9A-Z./+$%- ]*"
If (Me.VendorItemNumber) Like sPattern Then 'NOT WITHIN CODE39 SYMBOLOGY
MsgBox "You have entered an INVALID CHARACTER in this field." & vbCrLf & "Vendor Item Numbers must conform to Code39 symbology.", vbCritical, "Invalid Character!"
Cancel = True