The script below (create_user_list.bat) loops and creates 30 users. It works well on Windows Server2003 but is breaking on Server 2008. The error that is received is 'System error 5 has occured. Access is denied'.
Is there a permision level that needs to be changed in order to run the script?
set number=0
:start_loop
set /A number=%number%+1
if %number% GTR 30 goto end
net user company%number% i3z9nto! /add /comment:"10.5.2011" /expires:never /fullname:"Company User %number%" /passwordchg:no
net localgroup "Remote Desktop Users" company%number% /add
goto start_loop
:end