Skip to content

UsrMgr_EnableLocalUserAccount

Enables a local user account that has been disabled, for example with UsrMgr_DisableLocalUserAccount. The function fails if the user doesn’t exist.

The function doesn’t unlock an account that Windows has locked out after too many failed sign-in attempts.

UsrMgr_EnableLocalUserAccount(sUserName) As Boolean

The name of the user

If bStatus Then bStatus = UsrMgr_EnableLocalUserAccount("Username")

Scripting Guidelines

UsrMgr_DisableLocalUserAccount UsrMgr_CreateLocalGroup UsrMgr_AddUserToLocalGroup UsrMgr_SetLocalUserProperties Constants Package Property Variables