The command works well, I get a list of all users in that specific OU in a text file. Each user is listed in 1 line. But the problem is before the username and after the user name there are white space... How do I remove these whitespaces?
DSQUERY USER OU=firstou,OU=secondou,OU=thirdou,DC=child,DC=domain,DC=domain,DC=com| DSGET USER –SAMID >USERSLIST.TXT
|Windows server 2008||5||33|
|Do we need servers???||5||136|
|this script icacle doesn't work on remote computers. please help||11||33|
|Task with PowerShell Script is failing with 0x41301||7||41|
Join the community of 500,000 technology professionals and ask your questions.
Connect with top rated Experts
12 Experts available now in Live!