PowerShell, Active Directory : Uncheck password does not expire

If you have lots of accounts that have passwords set to never expire this script will hunt them out and correct that for you

Import-Module ActiveDirectory

#Search for the users
$NonExpireUsers = get-aduser -filter * -SearchBase 'DC=domain,DC=co,DC=uk'  -properties Name, PasswordNeverExpires | where {$_.passwordNeverExpires -eq "true" } |  Select-Object SamAccountName,Name,Enabled

Foreach ($NonExpireUser in $NonExpireUsers)
{
($NonExpireUser.SamAccountName) | Set-ADUser -PasswordNeverExpires:$false 
}