Problem
You want to modify properties of a specific user account.
Solution
To modify a user account, use the [adsi] type shortcut to bind to the user in Active Directory, and then call the Put() method to modify properties. Finally, call the SetInfo() method to apply the changes.
$user = [adsi] "LDAP://localhost:389/cn=MyerKen,ou=West,ou=Sales,dc=Fabrikam,dc=COM"
$user.Put("Title", "Sr. Exec. Overlord") $user.SetInfo()
Discussion
The solution retrieves the MyerKen user from the Sales West OU. It then sets the user’s title to Sr. Exec. Overlord and applies those changes to Active Directory.