Profile pictures in O365

%3CLINGO-SUB%20id%3D%22lingo-sub-192214%22%20slang%3D%22en-US%22%3EProfile%20pictures%20in%20O365%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-192214%22%20slang%3D%22en-US%22%3E%3CP%3EHI%20there%2C%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EI%20have%20users%20with%20and%20some%20without%20profile%20pictures%20in%20O365%20-%20please%20assist%20with%20a%20script%20or%20tool%20to%20extract%20a%20list%20of%20users%20%22without%22%20profile%20pictures%20in%20O365%3F%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EPlease%2Cplease%3C%2FP%3E%3CP%3EThank%20you!%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-LABS%20id%3D%22lingo-labs-192214%22%20slang%3D%22en-US%22%3E%3CLINGO-LABEL%3EExchange%3C%2FLINGO-LABEL%3E%3CLINGO-LABEL%3EOffice%20365%3C%2FLINGO-LABEL%3E%3CLINGO-LABEL%3ESharePoint%3C%2FLINGO-LABEL%3E%3C%2FLINGO-LABS%3E%3CLINGO-SUB%20id%3D%22lingo-sub-192615%22%20slang%3D%22en-US%22%3ERe%3A%20Profile%20pictures%20in%20O365%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-192615%22%20slang%3D%22en-US%22%3E%3CP%3EHI%20Christopher%2C%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EHow%20safe%20and%20secure%20is%20it%20to%20use%20Hyperfish%20as%20a%20Global%20Admin%20in%20your%20O365%20Tenant%3F%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-192600%22%20slang%3D%22en-US%22%3ERe%3A%20Profile%20pictures%20in%20O365%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-192600%22%20slang%3D%22en-US%22%3EGood%20one%20to%20test%20for%20future%20use...Thank%20you!%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-192597%22%20slang%3D%22en-US%22%3ERe%3A%20Profile%20pictures%20in%20O365%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-192597%22%20slang%3D%22en-US%22%3E%3CP%3EThank%20you%2C%20Sir!%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-192316%22%20slang%3D%22en-US%22%3ERe%3A%20Profile%20pictures%20in%20O365%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-192316%22%20slang%3D%22en-US%22%3EHyperfish%20also%20has%20a%20free%20tool%20for%20doing%20just%20photos.%20Their%20entire%20profile%20package%20is%20a%20nice%20upgrade%20option%20as%20well.%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-192299%22%20slang%3D%22en-US%22%3ERe%3A%20Profile%20pictures%20in%20O365%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-192299%22%20slang%3D%22en-US%22%3E%3CP%3EHi%20Derrick%2C%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3ETo%20manage%20user%20photos%20in%20Office%20365%2C%20you%20can%20use%20CodeTwo%20User%20Photos%20for%20Office%20365%20freeware%3A%26nbsp%3B%3CA%20href%3D%22https%3A%2F%2Fwww.codetwo.com%2Ffreeware%2Fuser-photos-for-office-365%2F%22%20target%3D%22_blank%22%20rel%3D%22nofollow%20noopener%20noreferrer%20noopener%20noreferrer%22%3Ehttps%3A%2F%2Fwww.codetwo.com%2Ffreeware%2Fuser-photos-for-office-365%2F%3C%2FA%3E.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EAll%20the%20best%2C%3C%2FP%3E%3CP%3EAdam%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-192249%22%20slang%3D%22en-US%22%3ERe%3A%20Profile%20pictures%20in%20O365%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-192249%22%20slang%3D%22en-US%22%3E%3CP%3EYou%20can%20add%20properties%20to%20the%20select%3A%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CPRE%3E%24allUsers%20%3D%20Get-Mailbox%20-RecipientTypeDetails%20UserMailbox%20-ResultSize%20Unlimited%20%7C%20select%20UserPrincipalName%2C%20Alias%2C%20DisplayName%2C%20%3CFONT%20color%3D%22%23339966%22%3EDepartment%2C%20LastLogonTime%3C%2FFONT%3E%3C%2FPRE%3E%0A%3CP%3E%26nbsp%3BFor%20the%20haspicture%26nbsp%3B-eq%20%24false%20you%20can%20add%20the%20else%20part%20of%20the%20if%2Felse%20statement%3A%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CPRE%3EIf(%24photo.PictureData%20-ne%20%24null)%20%7B%3CBR%20%2F%3E%20%20%20%20%20%5Bio.file%5D%3A%3AWriteAllBytes(%24path%2C%24photo.PictureData)%0A%20%20%20%20%20Write-Host%20%24user.Alias%20%E2%80%9Cprofile%20picture%20downloaded%E2%80%9D%0A%7D%0A%3CFONT%20color%3D%22%23339966%22%3EElse%20%7B%0A%20%20%20%20%20%23%20Insert%20your%20logic%20here%0A%7D%3C%2FFONT%3E%3C%2FPRE%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-192246%22%20slang%3D%22en-US%22%3ERe%3A%20Profile%20pictures%20in%20O365%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-192246%22%20slang%3D%22en-US%22%3E%3CP%3EHI%20Daniel%2C%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EAnother%20one%20-%20how%20do%20I%20add%20filter%20to%20output%20-%20DisplayName%2C%20UserPrincipalName%2C%20Department%2C%20LastLogonTime%20and%20haspicture%20-eq%20%24false%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EThanks%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-192225%22%20slang%3D%22en-US%22%3ERe%3A%20Profile%20pictures%20in%20O365%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-192225%22%20slang%3D%22en-US%22%3E%3CP%3EHi%26nbsp%3B%40Deleted%2C%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3ETake%20a%20look%20at%20this%20link%3A%26nbsp%3B%3CA%20href%3D%22https%3A%2F%2Fwww.jijitechnologies.com%2Fblogs%2Fhow-to-download-office365-user-profile-photo%22%20target%3D%22_blank%22%20rel%3D%22nofollow%20noopener%20noreferrer%20noopener%20noreferrer%22%3Ehttps%3A%2F%2Fwww.jijitechnologies.com%2Fblogs%2Fhow-to-download-office365-user-profile-photo%3C%2FA%3E.%20With%20a%20little%20modification%20(adding%20an%20else-statement)%20you%20will%20be%20able%20to%20get%20all%20people%20who%20don't%20have%20a%20user%20profile%20picture.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EKind%20regards%2C%3C%2FP%3E%0A%3CP%3EDaniel%3C%2FP%3E%3C%2FLINGO-BODY%3E
Highlighted
Deleted
Not applicable

HI there,

 

I have users with and some without profile pictures in O365 - please assist with a script or tool to extract a list of users "without" profile pictures in O365?

 

Please,please

Thank you!

8 Replies
Highlighted

Hi @Deleted,

 

Take a look at this link: https://www.jijitechnologies.com/blogs/how-to-download-office365-user-profile-photo. With a little modification (adding an else-statement) you will be able to get all people who don't have a user profile picture.

 

Kind regards,

Daniel

Highlighted

HI Daniel,

 

Another one - how do I add filter to output - DisplayName, UserPrincipalName, Department, LastLogonTime and haspicture -eq $false

 

Thanks

Highlighted

You can add properties to the select:

 

$allUsers = Get-Mailbox -RecipientTypeDetails UserMailbox -ResultSize Unlimited | select UserPrincipalName, Alias, DisplayName, Department, LastLogonTime

 For the haspicture -eq $false you can add the else part of the if/else statement:

 

If($photo.PictureData -ne $null) {
[io.file]::WriteAllBytes($path,$photo.PictureData) Write-Host $user.Alias “profile picture downloaded” } Else { # Insert your logic here }
Highlighted

Hi Derrick,

 

To manage user photos in Office 365, you can use CodeTwo User Photos for Office 365 freeware: https://www.codetwo.com/freeware/user-photos-for-office-365/.

 

All the best,

Adam

Highlighted
Hyperfish also has a free tool for doing just photos. Their entire profile package is a nice upgrade option as well.
Highlighted

Thank you, Sir!

Highlighted
Good one to test for future use...Thank you!
Highlighted

HI Christopher,

 

How safe and secure is it to use Hyperfish as a Global Admin in your O365 Tenant?