Scanner return null

123 views Asked by At

Im using a 3rd party library (Zxing) for bar code scanner . The result of scannig is null. After the scan I try adding the result into a label but the result is null.

Here is my code :

if (requestCode === SCANNER_REQUEST_CODE && resultCode === android.app.Activity.RESULT_OK) {
  // Handle successful scan
  var contents = intent.getStringExtra("SCAN_RESULT");
  var format = intent.getStringExtra("SCAN_RESULT_FORMAT");
  // var scanned = page.getViewById("scanned");
  //scanned.url = "";
  pageData.set("message", contents);
  page.bindingContext = pageData;
}
0

There are 0 answers