barcode scanner inputbox

H

Henk Wiering

I'm using datamatrix barcodes withtwo numbers separated with a carriage
return CHR(13)
Is it possible to create somethng like the statemant inputbox in vba that
read one scan into two variables in a form?
many thanks in advance
 
S

Sergey Poberezovskiy

Not sure about your terminology, but Split function will return you an array
with two elements you are after:
Dim myValues As Variant

myValues = Split(scannedString, Chr(13))
' then you could use this similar to the following:
myFirstVariable = myValues(0)
mySecondVariable = myValues(1)
 
H

Henk Wiering

Thanks for your answer, it will help me futher.
I can use the Split statement. I only have to change the CR delimiter,
because in an inputbox it will react like pressing the OK button.
 
Top