Showing results for 
Search instead for 
Did you mean: 
Level: Powered On

How to check if Camera access is granted

So, Building an app and have integrated both the option for users to utilize their camera and upload pictures.  I wanted to see if there was a way to check if the users either:

1) Did not authorize access to the camera
2) No camera is present on the device
3) Something squirrely happens and camera isn't interfacing properly


Intent is to hide the camera icons and replace them with the upload icons if there is an issue accessing the camera feed for whatever reason. 

Level 10

Re: How to check if Camera access is granted

This is an interesting one. I just put this together as a test. Put this code in your App's OnStart or Form's OnVisible property. I'm about to test this on my phone, I'll post my results.




This had some promise on my desktop version (returned true for CameraError), however it's not behaving as expected on mobile.

Level: Powered On

Re: How to check if Camera access is granted

Like the idea - however seems to be behaving oddly - on this one control it's populating with a blank picture icon which seems to be throwing everything for a loop.  if I do it based on just the URL line you provided it always throws up Error (Yes I know my column name is Pictures - that's after some tinkering try to make it work), even with the camera pre-allowed (Remembered). If I try to do it as IsBlankorError it's always False, because technically there is something there I suppose.

Only other aspect to consider would be allowing for users to have a few moments to actually click the button - gotta make it harder, you had an idea to fast!


Helpful resources

New Ranks and Rank Icons in April

'New Ranks and Rank Icons in April

Read the announcement for more information!

Better Together’ Contest Finalists Announced!

'Better Together’ Contest Finalists Announced!

Congrats to the finalists of our ‘Better Together’-themed T-shirt design contest! Click for the top entries.

Power Platform 2019 release wave 2 plan

Power Platform 2019 release wave 2 plan

Features releasing from October 2019 through March 2020


Community Summit North America

Innovate, Collaborate, Grow - The top training and networking event across the globe for Microsoft Business Applications

Top Solution Authors
Top Kudoed Authors
Users online (10,131)