10-10-2017 01:26 AM
hi everyone..
Im also scanning a barcode using scanner and im able to get a result of it aswell. But in my situation my scanning will be automatic and scanned value will be adapted by the labview automatically. In my case PC will be used by the operator and labview.exe may be minimised or running behind all desktop windows and he will be using PC for other purposes.In that case im not able to get the scanned barcode value even if its scanned,the scanned value is generated only if the labview is opened and its in front of all desktop windows and cursor is clicked on the control space provided.
Any one can help me in this situation,were we can read the barcode value even if its minimised or its behind all the desktop background running.
10-10-2017 01:57 AM
Hi sudhin,
barcode scanners usually just emulate a standard keyboard, so you need an active window with an active text/string input to receive the scanned code.
That being said you may try to use the low level "Input device" functions ( in the connectivity functions palette) to read any keyboard input. Now it's your duty to filter any relevant text input!
(There has been a thread with basically the same problem about 2 month ago, maybe you just start to search for this.)
10-10-2017 04:03 AM
THANK YOU SIR FOR YOUR QUICK REPLY..
Is there any way that i can make my labview active in all ways and it can read the scanned barcode values in it.I am new to this labview and cannot find any idea on this as well.
10-10-2017 04:36 AM
1. Place a String control (possibly you need a Focus property)
2. Shoot barcode reader
3. Profit.
10-10-2017 06:28 AM
1. Place a String control (possibly you need a Focus property)
2. Shoot barcode reader
3. Profit.
Here if the labview is behind any desktop window it does not read the barcode data. Labview .exe has to be clicked in order to read the data in the string control.
10-10-2017 08:05 AM
What do you mean by "read the bar code"? It is certainly possible to have a routine (in LabVIEW or some other application language) have a little window in the upper-right corner of the screen that shows the latest Bar Code value (and blanks after 3 minutes, if you want), but if you "cover it up" with another window, you won't "see" it.
You can also have a program that, for example, saves the Bar Code (maybe with a time-stamp) to a known file, and have your "What is the latest Bar Code Value?" software look at that file, but then you need to be able to control the caller program.
Sounds like your question is less a LabVIEW question and more a "how do I set up multiple simultaneous and totally independent tasks from various vendors to cooperate with each other?" question, an important, but difficult, question.
Bob Schor
10-10-2017 08:17 AM
@sudhin_sudh wrote:
1. Place a String control (possibly you need a Focus property)
2. Shoot barcode reader
3. Profit.
Here if the labview is behind any desktop window it does not read the barcode data. Labview .exe has to be clicked in order to read the data in the string control.
Quite true. If you set the VI to Modal it should stay in front.
/Y
10-12-2017 11:20 PM
HI BOB .....Thank you for your reply.
My barcode scanning will be done automatically by the robot.During that time operator may be working in the same pc doing his work on it. He may not understand when barcode is happening.So he will not be able to click the .exe labview before the scanning is happening.Is there any way that barcode scanned value is read in a labview which is running behind the desktop window.
Your faithfully
Sudhin
10-12-2017 11:58 PM
This is a three step process.
10-13-2017 02:52 AM - edited 10-13-2017 02:52 AM
There are barcode readers emulating a serial port over USB. The LabVIEW code could poll the port and drive any input to the proper wire.