locked
How do I format a User object property list by including an expanded array and all other properties? RRS feed

  • Question

  • Hi,

    I simply need the list of User object properties along with the expanded array of the attribute ProxyAddresses together in the same output.  When I perform a Get-Aduser Test1 -pr ProxyAddresses | Select -Expandproperty ProxyAddresses, all I get is the expanded array of ProxyAddresses, but not the other attributes.  When I perform a Get-Aduser Test1 -pr ProxyAddresses | Select * -Expandproperty ProxyAddresses, I get the same results which is just the expanded array list.

    Any suggestions?


    Thanks for your help! SdeDot

    Tuesday, January 9, 2018 5:01 PM

Answers

  •  Get-Aduser Test1 -pr ProxyAddresses | select *, @{n='Addresses';e={$_.ProxyAddresses -join '|'}}

    \_(ツ)_/

    • Proposed as answer by Naw Tuesday, January 9, 2018 11:58 PM
    • Marked as answer by SdeDot Wednesday, January 10, 2018 2:04 PM
    Tuesday, January 9, 2018 5:11 PM