Trying to pull Custom user attributes from AD


I am attempting to pull a list from AD with users and ALL their attributes. ( I am specifically interested in a certain few)

A command I have found which does this is: ([adsisearcher]“objectcategory=user”).findall() | select -expand properties

Which works (takes a long time) but I would like to output this data to a csv.

in other scripts I have added: | export-csv c:ADusers.csv

that produces a csv, but doesn’t contain the same results as when I use the command by itself…

I am still very new to PS,and really appreciate any assistance here.

submitted by /u/Kyratic
[link] [comments]

Leave a Reply