To enable the feature to prevent accidental deletion for all user objects within Active Directory, use the following PowerShell command.
Get-ADObject -filter {(ObjectClass -eq "user")} | Set-ADObject -ProtectedFromAccidentalDeletion:$true
The command above should enable the parameter for all user and computer accounts within Active Directory.
No comments:
Post a Comment
Note: Only a member of this blog may post a comment.