Hai Friends !
This is my first thread .I 'm developing a vb 6.0 application with barcode scanning enalbled.It's for Photo labs.I 've a bar code scanner connected via USB.It reads the barcode values .No problem with that.But when ever I scan a barcode,the value is stored in the text box and the application focus jumps to next tabbed control .My question is : How can I prevent this tab action from happening ? I want to store the scanned value in to a particular text box or to a vaiable only .. How can I do this? Please help !

There must be some code / event that is triggering the focus of the control.

Is there any change event coding on the textbox ?

Edited 6 Years Ago by debasisdas: n/a

There must be some code / event that is triggering the focus of the control.

Is there any change event coding on the textbox ?

The barcode scanner inputs the scanned value into the which ever Text box in focus at the moment.My question is ,I want to the scanned value to be stored in the particular text box only,say txtCvrNo
I already have a text box to enter some advance amount in the form.By some mistake if my client scans the barcode value in to this text box the application will consider it as advance amount. I want to avoid that.Is there any way ?

The scanner should have a configuration utility and with this utility you can specify characters appended to the string. In this case, the software is sending a tab character. You should be able to specify no character or another key press like enter if you are wanting to allow multiple entries into a multiline text box...

Good Luck

Hai Friends !
This is my first thread .I 'm developing a vb 6.0 application with barcode scanning enalbled.It's for Photo labs.I 've a bar code scanner connected via USB.It reads the barcode values .No problem with that.But when ever I scan a barcode,the value is stored in the text box and the application focus jumps to next tabbed control .My question is : How can I prevent this tab action from happening ? I want to store the scanned value in to a particular text box or to a vaiable only .. How can I do this? Please help !

Most bar code scanners append a newline character after the bar code data. Modern scanners let you disable this feature. Check your bar code scanner manual for details. The USB bar code scanners at barcodingfonts.com have tbis feature.

The barcode scanner inputs the scanned value into the which ever Text box in focus at the moment.My question is ,I want to the scanned value to be stored in the particular text box only,say txtCvrNo
I already have a text box to enter some advance amount in the form.By some mistake if my client scans the barcode value in to this text box the application will consider it as advance amount. I want to avoid that.Is there any way ?

barcode scanners works like any input device like a key board. it accepts the input in the control having focus only. so you need to scan / use the device while focus on desired control only.

This article has been dead for over six months. Start a new discussion instead.