public Form1() { InitializeComponent(); readSettings(); readPersonData(); readProductData(); readCategoryData(); readBarcodes(); initCategoryBox(1); //initPersonBox(1); initProductBox(); categoryBox.SelectedIndex = 0; personListBox.SelectedIndex = 0; productBox.SelectedIndex = 0; succesTone = this.CreatePolyTone2(1); errorTone = this.CreatePolyTone1(1); try { //create a instance of BarcodeReader class bcr = new BarcodeReader(); //set BarcodeRead event bcr.BarcodeRead += new BarcodeReadEventHandler(bcr_BarcodeRead); //sends the BarcodeRead event after each successful read bcr.ThreadedRead(true); } catch (Exception exp) { MessageBox.Show(exp.Message); } }
public Form1() { InitializeComponent(); readSettings(); readPersonData(); readProductData(); readBarcodes(); initProductBox(); succesTone = this.CreatePolyTone2(1); errorTone = this.CreatePolyTone1(1); updates = 0; MAX_UPDATES = 5; personInListArray = new Person[0]; try { //create a instance of BarcodeReader class bcr = new BarcodeReader(); //set BarcodeRead event bcr.BarcodeRead += new BarcodeReadEventHandler(bcr_BarcodeRead); //sends the BarcodeRead event after each successful read bcr.ThreadedRead(true); } catch (Exception exp) { MessageBox.Show(exp.Message); } }