Remove all phone numbers on all users in OU in Windows domain
To remove all phone numbers from all users in Windows domain in a certain OU, run PowerShell script to fix it
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Get-ADUser -SearchBase ‘OU=Desktop users,OU=Users and groups,OU=Lessor,DC=int,DC=lessor,DC=dk’ -Filter * | ForEach-Object {Set-ADUser -OfficePhone $null $_ } |
Kommentarer
Send en kommentar