H 16 - H 19 SDK

From OptiWiki

Jump to: navigation, search

The H 16 - H 19 SDK is an SDK which can be used in Microsoft Visual Studio .NET to be able to create some hardware specific source code.

The largest reason for using the SDK, is capturing scanned barcodes directly from the scanengine, rather than using the standard available keyboardhook.
This can for example be usefull if the user does not need to know/is not concerned about the actual data in the barcode.

I use the latest SDK and OS, but am still not able to get barcode data via the eventhandler!

Most likely there is an error in the sequence of creating instances of objects. This is fixed already, but currently (Sept. 4th, 2008), we are waiting for the driver to be signed. Following code works OK using the current SDK:

    public partial class Form1 : Form
    {
        private BarcodeDevice BarCodeDev = new BarcodeDevice();
        private ScanBarcode scanner;  //DO NOT INSTANTIATE JET!!!
 
        private void Form1_Load(object sender, EventArgs e)
        {
                BarCodeDev.BarcodeReaderEnabled = true;
                Thread.Sleep(1000);
                BarCodeDev.KeyboardHook = false;
 
                scanner = new ScanBarcode();
                scanner.BarcodeDataReceived += new ScanBarcode.BarcodeDataReceivedEventHandler(DataReceived);
        }
    }

Class not registered

COM Exception

This is an error message the will occur especially when developing for Windows Mobile 6. Windows Mobile 6 is more strict in using components.

To solve this issue, create a reference to the BCRServerCOM.dll, and set the Copy to Output Directory to the value Copy always. Now Rebuild the application.

Fix for BCRServiceCOM

I downloaded the latest SDK, and it seems that methods like 'dwSnapShot' are missing in the new DLL

The reason of this is not known, but seems to be Visual Studio related.

The DLL is correct. In most cases, it is solved by replacing ALL occurrences of BCRServiceCOM.DLL on your PC with the new DLL.
Also run Regedit, to see if there are any values in the registry pointing to other DLLs than the new one(s). Replace these values with a link to the proper DLL.

After this is done, just to be sure, change the properties of the BCRServiceCOMLib to the same as stated in picture Fix for BCRServiceCOM, and recompile the project.

Views
Personal tools