Monday, July 20, 2009

With (native) Windows NT 4+ commands:

    NET LOCALGROUP Administrators

Or, to remove header and footer lines:


FOR /F "delims=[]" %%A IN ('NET LOCALGROUP Administrators ˆ| FIND /N "----"') DO SET HeaderLines=%%A
FOR /F "tokens=*" %%A IN ('NET LOCALGROUP Administrators') DO SET FooterLine=%%A
NET LOCALGROUP Administrators | MORE /E +%HeaderLines% | FIND /V "%FooterLine%"

Share this

0 Comment to " "

Post a Comment