Quantcast
Channel: PowerShell.com – PowerShell Scripts, Tips, Forums, and Resources
Viewing all articles
Browse latest Browse all 6937

Formatting question

$
0
0

I need help breaking down a return into a single item list.. here is what I am doing

 $forest=[System.DirectoryServices.ActiveDirectory.Forest]::GetCurrentForest()

$forest.sites |Select @{ Name ="Site" ; Expression = { $_.Name }},

@{ Name ="Domain Controllers" ; Expression = { $_.Servers}}

For my second Expression "Servers" it is giving me a list of DCs for each site.. I was hoping to get a line break for each DC instead of having them all on the same line.

Any help is much appreciated

 

 

 

 


Viewing all articles
Browse latest Browse all 6937

Trending Articles