My code doesn't work!

My code doesn't work!

hi steven,thank you for answering my last question.Now I meet the new trouble .when my program runs at PC,shift+F1 hotkey can

callback the BarcodesScanned event correctly,but when i run it on the mca ,it doestn't work.Otherwise ,even on the mca,the

BarcodeButtonClick event seemed good.Is that the device have not release? I can use the barcodebutton to input the code to

the notepad.
my codes as below:
Intel.Healthcare.Device.Buttons btn;
EventHandler mBarcodeScannedHand = null;

public FormMain()
{
InitializeComponent();

btn = new Buttons(this.Handle);
mBarcodeScannedHand = new EventHandler(mBtn_BarcodesScanned);
this.btn.BarcodesScanned += this.mBarcodeScannedHand;
}

void mBtn_BarcodesScanned(object sender, BarcodeEventArgs args)
{

string displayStr = "the code is :" + args.BarcodeReader.Barcodes[0].Value + "<" + args.BarcodeReader.Barcodes

[0].Type.ToString() + ">";
MessageBox.Show(displayStr);
args.BarcodeReader.ReleaseDevice();

}

2 posts / novo 0
Último post
Para obter mais informações sobre otimizações de compiladores, consulte Aviso sobre otimizações.

Hi Sealot,

If the barcode is read when you push the physical barcode button, then that means you implemented it correctlyand that is the expected behavior. The shift-F1 action on a PC with the MCA SDK installed is meant to emulate the physical barcode button on an actual MCA hardware device such as the Motion C5. However, the shift-F1keyboard action is not expected to cause a barcode read on the Motion C5 because there is a physical button present.

-Steve

Deixar um comentário

Faça login para adicionar um comentário. Não é membro? Inscreva-se hoje mesmo!