ASKER
ASKER
ASKER
ASKER
ASKER
ASKER
ASKER
ASKER
ASKER
ASKER
ASKER
net localgroup > grouplist.txt
FOR /f "tokens=4 skip=6" %%a IN (HiredPersonnelTest.txt) DO call :proc_checkExistence %%a
del grouplist.txt
goto :eof
:proc_checkExistence
find /i "%1" grouplist.txt
if %errorlevel% equ 0 goto :eof
NET LOCALGROUP %1 /add
goto :eof
Microsoft Windows XP is the sixth release of the NT series of operating systems, and was the first to be marketed in a variety of editions: XP Home and XP Professional, designed for business and power users. The advanced features in XP Professional are generally disabled in Home Edition, but are there and can be activated. There were two 64-bit editions, an embedded edition and a tablet edition.
TRUSTED BY
FOR /f "tokens=4 skip=6" %%a IN (HiredPersonnelTest.txt) DO (
net localgroup %%a 2>nul
if not %errorlevel%==0 (
echo Usergroup %%a does not exist. Adding %%a
NET LOCALGROUP %%a /add
) else (
echo Usergroup %%a already exists.
)
)