Hi,
I create a powershell script to update a dynamic distribution group in Exchange 2010.
The script get the member of a users group and for each member the script change the custom attribute 5.
So far this the script :
#importe les commandes specifique a MS Exchange 2010 Add-PSSnapin Microsoft.Exchange.Management.PowerShell.E2010 #importe les commandes spécifique à l'AD import-module activedirectory #declaration varialble $memberGROUP = Get-ADGroupMember VPN foreach ($member in $memberGROUP) { $user = $member.name Set-Mailbox -Identity $user -CustomAttribute5 "vpn" }
I would like to test if the "CustomAttribute5" is not equal to "vpn" then if it is true the script change the value to "vpn".
Can you help me ?