[Camera.Reactive] Close Reactive camera
Forge component by Fábio Fantato

Hi everyone, i'm using the reactive.camera plugin for outsystems reactive, but i can't find how to close the web camera after use, camera is still open when i change screen.

Thanks in advance.

Hi,

I run Javascript code to close web camera:

stream.getTracks().forEach(function(track) {
  track.stop();
});

It works but it delays sometimes. I am looking for better solution.

Necmettin Sahinbay wrote:

Hi,

I run Javascript code to close web camera:

stream.getTracks().forEach(function(track) {
track.stop();
});

It works but it delays sometimes. I am looking for better solution.

Hi! This didn't worked for me.. I have the JS running from a button(Check-In) wich is in the same screen as the camera, and only appears after taking the picture...

 

How it is in Service Studio...

Using the aplication...

The Button who initiate the JS...

Button Flow...


Thanks in advance!

Check this link in https://varada-rajan525.outsystemscloud.com/SelfieAccess/TestCamera?_ts=637674193438785919

The JavaScript code which Necmettin Sahinbay has suggested work perfectly fine,
there might be some delay depending on the browser and device!!

Community GuidelinesBe kind and respectful, give credit to the original source of content, and search for duplicates before posting.