Printing a list of usernames/logon names

  • Thread starter Thread starter Dennis Woodward
  • Start date Start date
D

Dennis Woodward

Is there a way to print a list of usernames as well as the log name of all
users on the network.

I am using windows 2000 server.

Dennis Woodward
 
Is there a way to print a list of usernames as well as the log name of all
users on the network.

for /f "skip=4 tokens=1,2,3" %a in ('net user /domain') do net user
%a /domain|find /i "name">>user.txt&net user %b /domain|find /i
"name">>user.txt&net user %c /domain|find /i "name">>user.txt

Single line!

Ciao, Walter
 
Is this for a network with multiple domains? I am totally lost.

I have tried to enter the suggestion from the run box as well as the cmd
prompt. At the cmd prompt, it tells me the syntax is wrong and I have tried
to do what the help screen suggests but am missing something.

I have one domain which is called 'manet'. Any other offerings?
 
Is this for a network with multiple domains? I am totally lost.

No, this works for a single domain only.
The command consists of a single line. Begins with "for /f" and ends
with "%c /domain|find /i "name">>user.txt".


Ciao, Walter
 
Back
Top