Hi,

I need to create, copy, rename and reset passwords for user obejcts that are
local to a computer (both Windows XP and Windows Server 2003).

I've browsed through the Windows 200 Scripting Guide, which I must say seems
rather comprehensive, but I can only find information on Active Directory
users.

If anyone could point me to where I can find information on local user
objects, I'd be much obliged!

Regards,
Jørn

Re: Managing local user objects by Richard

Richard
Sat Feb 07 12:04:34 CST 2004

Jørn Jørgensen wrote:

> I need to create, copy, rename and reset passwords for user obejcts that
are
> local to a computer (both Windows XP and Windows Server 2003).
>
> I've browsed through the Windows 200 Scripting Guide, which I must say
seems
> rather comprehensive, but I can only find information on Active Directory
> users.
>
> If anyone could point me to where I can find information on local user
> objects, I'd be much obliged!

Hi,

The process is pretty much the same, except that you must use the WinNT
provider for local accounts. A few links in the TechNet Script Center give
example:

http://www.microsoft.com/technet/treeview/default.asp?url=/technet/scriptcenter/user/default.asp

For example, to create a local user:
http://www.microsoft.com/technet/treeview/default.asp?url=/technet/ScriptCenter/user/ScrUG92.asp

To create a local group:
http://www.microsoft.com/technet/treeview/default.asp?url=/technet/ScriptCenter/user/ScrUG90.asp

Setting local user password never expires:
http://www.microsoft.com/technet/treeview/default.asp?url=/technet/ScriptCenter/user/ScrUG115.asp

Add user to local group:
http://www.microsoft.com/technet/treeview/default.asp?url=/technet/ScriptCenter/user/ScrUG69.asp

Other example enumerate groups or users, or display properties of users.

--
Richard
Microsoft MVP Scripting and ADSI
HilltopLab web site - http://www.rlmueller.net
--