Failed to connect to camera service

前端 未结 10 2046
梦毁少年i
梦毁少年i 2020-11-28 10:13

I\'m trying to access the camera on my phone. I\'m writing a simple stub app prior to putting the code in a widget. I\'m not getting very far. The code always throws a runti

10条回答
  •  甜味超标
    2020-11-28 10:51

    since this question was asked 4 years back..and i didn't realised that unless mentioned by the Questioner..when there were no Run time permissions support.

    but hoping it useful for the users who still caught in this situation.. Have a look at Run Time Permissions ,for me it solved the problem when i added Run time permissions to grant camera access. Alternatively you can grant permissions to the app manually by going to your mobile settings=>Apps=>(select your app)=>Permissions section in the appeared window and enable/disable desired permissions. hope this will work.

提交回复
热议问题