Hi im trying to scan multiple objects in the same scann or maiby make a loop for the scann call but when i try to stop it the app companion crash here are my blocks atm.
the idea is after one scann is completed save this value to a list (this function properly) and the start then scan again to scan another object.
Instead of a timed loop, use a recursive function.
Barcode scanner1 call Scan
The “then do” part of the block will make sure the current scan has completed before attempting the next scan. The “scan” function call at the end will restart the process.
In your when “Button2 Click” block, you just need a single block: “scan”.
let me test this, hope this works tnx
so this let me scann multiple objects at the time but when i need to stop (cancel button) it crash de
i was thinking on work whit the “was cancelled” value any sugestions ??
i get it right mi error was cause because when i press cancel button i dont get the “value back” so crash the copanion i add a little if and the problem was solve ty for the first part
Glad to hear you got it working! Yes, you always want to check the value of any green “error” or “was cancelled” blocks. If you try to access list data or data sources and the value is null or empty, your app may crash.