How to implement barcode rules

Hello,

To read an EAN13 with supplemental, in many cases we need to create barcode rules on scanner devices.

I need to get the same behavior on an MK31 running EB but I do not see how to implement a barcode rule in EB.

Is barcode rule supported in EB ?

How can I get examples on how to do it ?

 

Thanks

Regards

Pietro Francesc...
Hi Erick,I don't have an MK31

Hi Erick,

I don't have an MK31 to test this code, but usually I use EB's Barcode API with the parameter to enable EAN Supplementals:

EB.Barcode.enable({allDecoders:true, upcEanSupplemental5:true, upcEanSupplementalMode:EB.Barcode.UPCEAN_AUTO}, fnScanReceived);

Getting the data in the usual way:

function fnScanReceived(params){

    if(params['data']== "" || params['time']==""){

        $$('#barcode').innerHTML = "Failed!";

        return;

    }

    var displayStr = "Barcode Data: " +params['data']+"<br>Time: "+params['time'];

    $$("#barcode").innerHTML = displayStr;

}

Let me know if you need a complete sample.

~Pietro

Vote: 
Vote up!
Vote down!

Points: 0

You voted ‘up’


Erick Rondin
Hi Pietro,Thanks for your

Hi Pietro,

Thanks for your info but I am not sure how to use it. If you have a complete sample I would appreciate.

Just a detail to point that enabling barcode supplemental does not match with the expectations, same as using a barcode device. For that reason the only way to make it works is to use a rule that manage correctly the read informations from the scanner and I am looking for how to do the same in EB.

Vote: 
Vote up!
Vote down!

Points: 0

You voted ‘up’


Log in to post comments