I have a canvas app with the SharePoint and the Office365Users connectors. I would like to display a user's Office 365 photo in a gallery if the user has a photo, or show a generic profile photo if they don't. The connected SharePoint list includes a person field, which is where the user photos are coming from.
The gallery works as intended by displaying the user's photo if they have one and showing a generic profile image if they don't. However, I'm getting this error when I run the app:
Here's what I have for the Image property on the photo in the gallery:
If(Office365Users.UserPhotoMetadata(ThisItem.SP_Person.Email).HasPhoto = true, Office365Users.UserPhotoV2(ThisItem.SP_Person.Email), 'No-Profile-Photo')
Here's the warning from Power Apps on the formula for the Image property: "This formula uses scope..."
Solved! Go to Solution.
Thanks! That seems to work. I updated the Image property on the photo in the gallery to this:
Keep up to date with current events and community announcements in the Power Apps community.
A great place where you can stay up to date with community calls and interact with the speakers.
Check out the latest Community Blog from the community!