Link to home
Start Free TrialLog in
Avatar of techdrive
techdriveFlag for United States of America

asked on

calculated properties windows 7 connected to windows 2012 domain

I am typing In the following command get-aduser username -properties memberof | select-object  {$_.memberof}  I was hoping to get the following output. For some reason I am not. I am using a windows 7 machine and have done the import-module active directory.


group1
group2
group3
group4

I was wondering why is this not occurring here.
ASKER CERTIFIED SOLUTION
Avatar of SubSun
SubSun
Flag of India image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of techdrive

ASKER

sweet thanks it worked. So can I use this method for almost any multi valued comma delimited property. If I am using the correct terminology.
If you are trying to export result, I would suggest you to use the custom property option so you can export all required properties of user.. Example..
Get-ADuser username -properties memberof | Select Name,SamaccountName,@{N="memberof";E={$_.memberof | Get-Adgroup | select -exp Name}}

Open in new window

like always thank you very much for your help. You have always been extremely helpful.
very helpful
You are welcome!