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

how to remove spaces from text?

$
0
0

Hi, 

 

this command write all servers name into TXT file, the problem that after every name the command add blank spaces, how can I remove them?

Get-ADComputer -Filter {OperatingSystem -Like "Windows *Server*"} -Property * | Format-Table Name -Wrap -Auto| out-file c:\servers.txt

 

 

Thanks

Lior 

 


Viewing all articles
Browse latest Browse all 8583

Trending Articles