# Problem with having a webcam work consistently using the QR code element

**URL:** <https://community.weweb.io/t/problem-with-having-a-webcam-work-consistently-using-the-qr-code-element/8945>\
**Category:** How do I?\
**Created:** [June 4, 2024, 4:57am UTC](https://community.weweb.io/t/problem-with-having-a-webcam-work-consistently-using-the-qr-code-element/8945 "2024-06-04T04:57:45Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Atlas](https://avatars.discourse-cdn.com/v4/letter/a/0ea827/32.png) [@Atlas](https://community.weweb.io/u/Atlas)\
**Post date:** [June 4, 2024, 4:57am UTC](https://community.weweb.io/t/problem-with-having-a-webcam-work-consistently-using-the-qr-code-element/8945/1 "2024-06-04T04:57:45Z")

</div>

I saw in another post that I can access the webcam using a QR code element and capture an image there. However, I am having a problem consistently activating the webcam. It works fine the first time, but when the page is refreshed or, in my case, when a modal is closed and reopened and I try to access the webcam again, it fails and doesn’t show any image. Is there a known bug with the QR code element?

Specifically, I am getting this error: [DOMException - The play() request was interrupted &nbsp;|&nbsp; Blog &nbsp;|&nbsp; Chrome for Developers](https://developer.chrome.com/blog/play-request-was-interrupted)

Thank you!

---

<div class="post-metadata">

**Author:** ![forgelab](https://sea2.discourse-cdn.com/flex016/user_avatar/community.weweb.io/forgelab/32/9671_2.png) [@forgelab](https://community.weweb.io/u/forgelab)\
**Post date:** [July 1, 2024, 3:08pm UTC](https://community.weweb.io/t/problem-with-having-a-webcam-work-consistently-using-the-qr-code-element/8945/2 "2024-07-01T15:08:39Z")

</div>

hi @Atlas in case you’re still looking for QR code + barcode functionality, we built and released a free component on the new WeWeb marketplace that scans both QR and barcodes.

[https://marketplace.weweb.io/projects/18ecff92-25f0-4da3-8818-b52ca9ee38fd/](https://marketplace.weweb.io/projects/18ecff92-25f0-4da3-8818-b52ca9ee38fd/)
