Change Administrator Account on Multiple Computers

I need to rename and change the password for the local administrator account on my Window XP Pro machines.  Is there a script of utility that I can use to accomplish this.  Any help is appreciated.

Thanks in advance
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

If you are in an active directory domain you can use a machine group policy to accomplish this. If you need to apply it only to specific machines you can create/move them into a specific OU   OR create a security group, add those machines, then specify the GPO to only allow that security group to read the GPO.
hope that helps,
changing the password can be done with a machine startup script via the same GPO.
net user <newadminname> <newpassword>
GilardiCoAuthor Commented:
This works good to change the password, however I need to also rename the administrator account.

Check the discussion here:
The 2nd script can be used to change the local admin account name to random 15 characters...
Introducing Cloud Class® training courses

Tech changes fast. You can learn faster. That’s why we’re bringing professional training courses to Experts Exchange. With a subscription, you can access all the Cloud Class® courses to expand your education, prep for certifications, and get top-notch instructions.

GilardiCoAuthor Commented:
That should work, I just need to change it to a specific name.
' This code renames the local administrator account.
strComputer = "."
strNewName = "<NewUserName>"  ' e.g. mike
' ------ END CONFIGURATION ---------

set objComputer = GetObject("WinNT://" & strComputer)
set objUser = GetObject("WinNT://" & strComputer & _
set objNewUser = objComputer.MoveHere(objUser.ADsPath,strNewName)
WScript.Echo "Successfully renamed account to: " & strNewName

Push this out as a startup script...

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
GilardiCoAuthor Commented:
That worked, thanks for the help.
Glad that helped. Thank you.
GilardiCoAuthor Commented:
Hello there,

Your script works great, however if the Administrator account is already renamed then it comes up with an error.  Anyway to build in a if then type situation so if no Administrator account exists then do not run the rest of the script?

Once again any help is appreciated.
It might be better to ask a new question in the vbscript TA - there are some really good Experts in there...
Someone should be able to help quite easily.
After all - PSM's are supposed to ask one question "per question"...
Feroz AhmedSenior Network EngineerCommented:
Right click on MyComputer select Manage and select Local Users and Groups and select the Administrator Account and right clik onto it and rename Administrator Account and once you are done with Renaming Administrator Account you can reset Password in the same way and in this manner you can change administrator account as well as reset password.
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Windows XP

From novice to tech pro — start learning today.