I'm trying to end up with a txt file of usernames (1 user per line) using the
net group /domain <group>
command. However, the output of this command is not conducive to parsing. Does anyone have a way to pipe this to a txt file so that the file consists of only one user per line?
Ok, no additional installs, I get it. The following is horrible, horrible, and I would suggest there must be a better way [use the AD module!] to do it. I didn't feel like writing this in batch just now, so here it is. Note there isn't even a hint of i18n, error handling or anything "sane" here.