Question

Capture from Camera issue in Mobile Application

Hi Community,

I'm currently working on Creatio mobile application (Classic UI), and I've encountered an issue with the Terrasoft.Camera.captureFromCamera() function. I've set up a custom button that, when clicked, is supposed to open the camera. However, I've noticed that the success callback is being triggered upon clicking the custom button, rather than after capturing an image as expected.

Here's a snippet of the code I'm using:



Terrasoft.Camera.captureFromCamera({

    quality: 80,

    success: this.onCameraCapture,

    failure: this.onCameraFailure,

    scope: this

});

The onCameraCapture function should ideally be called after the user captures an image in the camera,but it seems to be triggered upon clicking the custom button instead.

 

Can you help me on this?

 

Like 0

Like

2 comments

Hello Pavan,

 

I checked calling the onCameraCapture method in the MobileFileAndLinksEmbeddedDetailGenerator module (attaching a photo to the attachment detail in any section) and the onCameraCapture method is called only after the photo is taken and selected to be uploaded. Please check the code used there, it should help call the same login upon a custom button click.

Oleg Drobina,

I am also facing an issue with reading the file. The file was empty.

Show all comments