OK, so if you use a barcode scanning solution that's currently available (http://bruji.com/cocoa/barcode.html), it will keep scanning until it reads a valid barcode.  Once completed, it will enter the barcode.  I suppose if there is a hidden field, which only the program can input the text, it would work.  The only downside I can think of is if someone were to find a way to enter the text in manually, bypassing it. 
_________________________
MacBook 2GHz Intel Core 2 Duo w/ 2GB DDR2 RAM & 120GB SATA 5400RPM HDD
Canon Rebel XTI
Google Cr-48 Beta Laptop