exporting thumbnailPhoto attribute to HTML / .jpg

This topic contains 1 reply, has 1 voice, and was last updated by  sponsen 4 years ago.

  • Author
    Posts
  • #11109

    sponsen
    Participant

    Hi,

    I'm trying to export the thumbnailPhoto on ADusers and be able to display the images as HTML or "convert" the bytes back to a .jpg file.

    I guess it should be quite simple, I'm just not able to figure it out 🙂

    This is where I'm at now... 😉

    Get-ADUser user -Properties thumbnailPhoto | Select-Object -ExpandProperty thumbnailPhoto 
  • #11119

    sponsen
    Participant

    I finally found a solution!

    Get-ADUser user -Properties thumbnailPhoto | Select-Object -ExpandProperty thumbnailphoto | Set-Content -Path C:\path.jpg -Encoding Byte

You must be logged in to reply to this topic.