cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
omi18
Post Partisan
Post Partisan

Display Image

Hello,

 

I have the image item set to "Office365Users.UserPhotoV2(Gallery5.Selected.email1)" and it shows the image of the O365 user. 

 

What I'm trying is if there no image for the O365 user then show a different image. Can we do this in powerapps?

 

Any suggestions? 

 

Thanks,

Omi

1 ACCEPTED SOLUTION

Accepted Solutions
James_McKie
Advocate II
Advocate II

You can use the UserPhotoMetadata to determin if they have a photo and then act accordingly, 

e.g.

If(Office365Users.UserPhotoMetadata(Gallery5.Selected.email1).HasPhoto, Office365Users.UserPhotoV2(Gallery5.Selected.email1), SampleImage)


View solution in original post

2 REPLIES 2
James_McKie
Advocate II
Advocate II

You can use the UserPhotoMetadata to determin if they have a photo and then act accordingly, 

e.g.

If(Office365Users.UserPhotoMetadata(Gallery5.Selected.email1).HasPhoto, Office365Users.UserPhotoV2(Gallery5.Selected.email1), SampleImage)


omi18
Post Partisan
Post Partisan

Hi @James_McKie ,

 

Worked as expected. 

 

Thanks,

Omi

Helpful resources

Announcements
Power Platform Conf 2022 768x460.jpg

Join us for Microsoft Power Platform Conference

The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.

Users online (4,225)