I’m trying to export Active Directory group members using “Get Object Properties” with singleproperty “member”. The value that I am getting back is system.object. How can I convert that to something that is enumerable; that way I can see all of the different members?
Or, is there an alternate way of doing this? Goal is to generate a .CSV file containing all of the members in an AD group.
The output System.Object[] is an Array of Objects. Try logging strGroupMembers.Length.ToString() to see how many objects are in the Array. You can go through them one-by-one by using strGroupMembers as the value in a For Each loop.