Re: Deny local user the ability to change password by Ray
Ray
Tue Sep 14 10:47:35 CDT 2004
The simplest way would be to "shell out" and execute net user username
/PASSWORDCHG:NO
i.e.
Dim oShell, sUsername
sUsername = "testuser"
Set oShell = CreateObject("WScript.Shell")
oShell.Run "%comspec% /c net user " & sUsername & " /passwordchg:no", 0,
true
Set oShell = Nothing
Ray at work
"Daryl" <dclark03@7-11.com> wrote in message
news:ehZwJCnmEHA.648@tk2msftngp13.phx.gbl...
> Does anybody know what code i would need to use to deny a local user
> account
> the right to change their password. I can find plenty of code for Active
> directory accounts but none for local user accounts
>
>