Android SecurityException: Permission Deniel for CAMERA permission in the AndroidManifest file

255 Views Asked by At

I'm using ActivityResultAPI for capturing photos in my app so as I'm using this API I can't include CAMERA permission in Manifest file right.

But now in my application there is barcode scanner feature for that I need camera permission to be added into manifest file.

But it gives below exception while using take picture feature but works fine for barcode sacn feature..

java.lang.SecurityException: Permission Denial: starting Intent { act=android.media.action.IMAGE_CAPTURE flg=0x3 cmp=com.android.camera/.Camera clip={text/uri-list {...}} (has extras) } from ProcessRecord{67b91af 8305:com.ehr.myairmed/u0a422} (pid=8305, uid=10422) with revoked permission android.permission.CAMERA

Is there any alternative solution for this problem? Thanks.

0

There are 0 best solutions below