[FREE] ScanView -ZxingView Version 2- Extension

please write in English
Taifun

1 Like

@jeferson_gibion
All the best! And happy Koding!

if you have any problem, please explain it here or PM me.

1 Like

Help Needed
ScanView Version 3 is coming!

For contributing in this extension please read the Announcement in the first post.

2 Likes

There are many possibilities for using qrcode with this extension.
@Silver He always supports us when we ask for help.
The application you built is an example of a USEFUL application. Kodular allows us an easy way to start a productive and useful application, it depends on our skill, creativity and dedication. Using web systems, with a local database or/and on the web, together with the apk created by Kodular are examples of useful and productive applications. However, you should be careful as the platform is in the migration phase. Make your planning. so that your USEFUL work is not lost.

1 Like

Hello
Is this version working properly on App Inventor2 ? Sample app is not working at 07-23-2024.

Welcome! Please read this:

Is there a way to scan multiple QR codes at once? I mean in one scanning frame, to be able to scan multiple QR codes simultaneously and display a list of them

Hay @Resulf_Lee Welcome to the community, your use case is not supported by ScanView.

1 Like

Could you consider adding that feature in the next update? It will help reduce the time spent scanning QR codes. Instead of scanning each QR code individually, we could scan and read multiple QR codes in one scan.

ScanView extention depends on Zxing library, zxing library doesn’t support this feature as far as I know, but suppose the feature exists, how do plan to index the scanned results to the corresponding qr code?

1 Like

create a mapping system that links scanned results to the corresponding QR codes based on the chosen identification method. This mapping should be dynamic to handle different numbers of QR codes in each scan and store these results in a ListView.
I have seen some tools that can recognize multiple QR codes at once, with each position being a QR code recognition frame. After the recognition is completed, the data will be written to a list

  • Yes it’s
  • It can be done to (I made an app to register participants, take attendance, and ask questions (both audio and text) dynamically for a talk I gave at a university ussing it).
  • You talk as if you know how to do it, but it’s actually more complex. :rofl:
  1. It can be scanned continuously, the library has no limitations in this regard, the limitations are only in knowledge, insight and technique.
  • If you re-read this post You will find that the extension has the stop and start option, as well as that it is about putting it in a vertical arrangement.

Then, create a new screen, put a Verctical Arrangement and a Horizontal Arrangement, On the vertical one sets the scanner, on the horizontal one the scann button.

  • Every time the button is pressed, start scanning > get result > stop scanning > do the checks and operations you need with result > start scanning (again).

  • That way the scan arrangement never stops scanning (as it is always visible).

  • When you close the screen (necessary so that the camera doesn’t continue scanning and finishes the process properly), make sure that all the data you needed has been saved correctly.

About your Mapping System:

  • If you scan a QR it gives you a result, that QR (with that result) can be easily recreated, so you don’t need to “map” anything. it is enough to assign a “TAG” or “TITLE” to that result, whether it is in a TinyDB or ListVIew.

Ex: QR_from_My_Dog = Result of scanning. And if you need de “image QR” again, just create it :tipping_hand_man:

  • Obviously it must be dynamic, because you will never know (from continuous scanning) how many results you will have.

But all this will depend on the particular need of your specific case.

Recommendation:

  • When it comes to scanning, you should always, always, always, always, take security seriously, perform security checks, especially in terms of the result obtained, because literally anything can be coded (even malicious code).

  • Make sure that what you scan is a QR and not a PDF417 or ISN, etc. As well as that it is compatible with the type of data that corresponds to your case (number, text, link, bool, etc.), whether or not it has the characters you need (@/*±_ ;).

Ex:

  • What if your app needs to scan just one character? (CHAR) = “a” and someone with bad intentions puts “ABCDEFG” or “3” or “True/False”, etc.

  • As well as if you are working with BDD Sql and it makes a SQL injection, or in your form where it should say the Nationality you see “Powny”.

From :argentina: with the :hearts: for the :globe_with_meridians:

1 Like

Yes it does!

@Jonathan_Andres_Urbina_Ca Thank you for your insights!

1 Like

Friend… You can’t imagine what this extension means to me, it’s not just because of the fact that it scans all kinds of formats, but the fact that it shows what kind of format I scan… It’s enough!, because as I said above, with it you can do all kinds of checks and logic necessary to maintain the integrity and security of any application, program or system.

Yeah, obviously it would be better to be able to filter/choose the type of format to scan, and blah blah blah.

  • But a rescued dog doesn’t count its fleas :rofl:

I’m currently working on a way to create/recreate the WhatsappWeb login style.

  • To sign in from your phone to a computer, but respect the privileges, roles, and UI of the user signing in.

Ex: administrator, data scientis, professor, student, etc.

Broadly speaking, it doesn’t seem difficult or complicated, but at the level of Backend, security and integrity of the platform… Yes, it is.

Especially when talking about sensitive or critical data (view, CRUD, transfer, etc.), or automation processes (industrial, iot, etc.).

The ML Kit off google it’s good, but i dont trust in google, it’s like I dont see your data :face_with_peeking_eye:

:saluting_face:

I use similar way did my app, but somehow it struggle in 2nd/3rd scan, the first scan was fast and easy,
but after I got first QR result, which use “stop scanning”, and back to scan screen again, I can see the camera refocus a lot but not get any result,

I have to restart my page to get next result, but sometime, it’s work (very rare) and quick got 2nd result, I try use different device, but same problem keep happened, I have no idea why.

I was tried to close the autofocus , but it’s not work.



some data infomation use chinese name, so I put note on it.

this is the video to show the situation, the demo device is Samsung S23 Ultra, I think this device which has high ability for camera focus, but still had problem on it.

and sorry for my poor English, I try best to use translat to describe.

Sorry for the delay, try to put the “StopScan” in the beginning, then do all the stuffs.

  • The camera still scanning while you do the cheks and all the thinks

That carry many problemas with memory and computation.

@06D

Happy Koding my Friend, all the best with your work, you mentioned you are working on a WhatsApp related project, I can suggest you this link and I think it can be helpful to you:

1 Like

Thanks for reply, I try this suggestion but not work,
And I think I found the problem from, the scan has not allow same qr code scan twice (or some kind time delay for same qr code), that’s why that scan work everytime I switch page back, it’s clean memory when I left scan page.
The “stopscan” funtion won’t clean the memory, so when “startscan” again, it still block the first Qr result. I not found funtion to adjustment that part.

1 Like

I tried to replicate your error, but on the devices I have at my disposal I was able to do so, so it could be something according to your device, android API, etc.

  • Instead, you/we could take the following approach.

1- We know that the Arrangement container the Scanner is a vertical one.
2- We know that it must be “updated” in order for it to work as it should (or want).
3- We know that Appinventor does not have or contains an “update component” option, and the existing ones are not optimized.
4- Then we have to “create” and “destroy” the component, dynamically, so that it is “updated” …
5- And we know that the only way to do it or do something like that, is through “Dynamic Components”.

  • Then…

1- In order for the dynamic components to work as they should, we need a container.
2- Then create 1 Vertical Arrangement [AK: VAC] (Statically: via UI), To contain your dynamic component.
3-- Create a dynamic component Vertical Arrangement as a/for the Scanner Container (AK: VASC) insidie the VAC you’ve already created.
4- Inside VASC create (dynamically) the Scanner component and start scan
5- Store the scan in a List (Global ListScans) then stop scan
6- Then destroy (dynamically) the created VASC
7- LOOP (Step 3 to 6)

  • In this way, the Arrangement will be “updated” and will allow the continuous scanning of the same or different QR’s, etc.

  • I recommend you approach this procedurally and synchronously (to avoid spaghetti code and buffer and memory problems)

  • Example:

1- Create a screen that contains a button that says Products Scanning (Main Screen)
2- Create a screen that contains 2 buttons that says Start Scan and another Stop Scan. with VAC (Scan Screen)
3- Create the procedures;C_VASC (Create Vertical Arrangement conteiner for the scann component), C_SC (Create Scanner inside VASC), D_All (Destroy all).

In C_VASC:

  • Create VASC And passes its ID as a parameter to C_SC
  • Use the ID of VASC to create the Scanner component inside of it, using his ID

In C_SC:

  • Create de component Scanner > Perform de Scan > Stop Scan > Store it in Global ListScans > And passes its ID With VASC ID as a parameters to D_ALl

In D_All:

  • If button “Stop Scan” it’s not pressed Then (case) > Destroy SC by ID > Destroy VASC by ID > Create a new VASC > Create a new SC
    Else (case) > Destroy SC by ID > Destroy VASC by ID > do what you need with Scaned values stored in Globas ListScans > Close Screen > Go to Screen what you want.

  • That way you create a quasi-infinite Loop, which creates and destroys the components by performing the selected tasks in each one.

  • I don’t recommend creating it through For, Do While, etc (Loops). Because more resources (time and processing) are consumed.

  • The procedural approach (synchronous and asynchronous) is the best for appinventor (because of the block issue)

  • But always remember that each procedure should do a single and unique task.

You can have a main procedure that calls other procedures synchronously or asynchronously, Ex:

  • Caller_Sync_Proc: Call Proc1 > Proc2 > Proc3 > Proc[n+1] when Proc1 finish, then execute Proc2 and so on.

  • Caller_Async_Proc: Call Proc1 > Proc2 > Proc3 > Proc[n+1] then execute all Proc[n] at the same time.

  • Through this procedural approach, your code (blocks) will always be ordered, and by following method 1 procedure 1 task, you will always have control of errors in your code, because you will know which task is the problem. It will also allow you to have your blocks ordered in a hierarchical way and in order or execution time.

  • Cause, you will always know which procedure calls another procedure, which procedure does/perform ‘x’ task, as well as reuse blocks (procedures) that are common to other procedures.

Try and let me know if it worked.

From :argentina: with :heart: to the :globe_with_meridians: