Zebra DS9308 Scan Event Query

// Expert user has replied.
c cho wally 8 months 2 weeks ago
58 1 0

Hi,

  I'm new to Zebra, and when I use CoreScanner SDK to fire BarcodeEvent as sample code Zebra provides. Ideally I want to write a function after Zebra gets barcode back as following codes but it doesn't work. Can someone help me ?

Thank you.

 

   void OnBarcodeEvent(short eventType, ref string pscanData)
  {
      string barcode = pscanData;
       this.Invoke((MethodInvoker)delegate { can I write a function to execute data ? });      
  }
Please Register or Login to post a reply

1 Replies

R Riad Benallou

Hi Wally 

Did you execute the REGISTER_FOR_EVENTS method with the SUBSCRIBE_BARCODE event type?

 

executes an Open for all types of scanners and an ExecCommand with the REGISTER_FOR_EVENTS method using the following XML and a GetScanners API call:

  1. 
    <inArgs>
        <cmdArgs>
            <arg-int>6</arg-int>
            <arg-int>1,2,4,8,16,32</arg-int>
        </cmdArgs>
    </inArgs>
    

NOTE The first <inArgs> tag in the XML is filled with the number of events you want to register. In the example above, number of event it wants to register is "6". The second tag is filled with the event ids that you want to register separated by the commas (","). See event IDs in table below.

Table 2: Supported Event IDs

Event Name                            Event ID 

 SUBSCRIBE_BARCODE               1

SUBSCRIBE_IMAGE                     2

SUBSCRIBE_VIDEO                      4

SUBSCRIBE_RMD                         8

SUBSCRIBE_PNP                          16

SUBSCRIBE_OTHER                      32


 

 

CONTACT
Can’t find what you’re looking for?