• barkertie demannson
  • NEWBIE
  • 0 Points
  • Member since 2023

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 0
    Questions
  • 2
    Replies
Using the Barcode Scanner API in Salesforce, is there a way to enable Torch for scanning during night time?

There doesn't seem to be an option for it in BarcodeScannerOptions.

I tried using an iframe to start video recording and enable the torch, but when starting the Barcode Scanner API, it seems to turn it off again automatically, before scanning.

A code sample of the API
 
const scanningOptions = {
    barcodeTypes: [ scanner.barcodeTypes.EAN_13 ],
    instructionText: 'Scan barcode',
    successText: 'Scanning complete.'
}; 

const result = await scanner.beginCapture( scanningOptions );