Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

disable-mailuser doesn't remove WindowsEmailAddress

119 views
Skip to first unread message

Tim Munro

unread,
Oct 15, 2009, 8:59:10 AM10/15/09
to
Hi all,
Not sure if this an Exchange or Powershell issue so I've cross posted.
(I hope that's the proper etiquette).

The Cmdlet "disable-mailuser" does not clear the WindowsEmailAddress
field. If a user object is mail disabled why would a (probably invalid)
email address be left? Is this bug? If this is deliberate can some one
please divulge the reasoning behind this (just curioous at this point)?

Other than the Quest Cmdlets or a VBScript, is there a powershell way to
clear this field?

Thanks.

--
Tim.


Karl Mitschke

unread,
Oct 15, 2009, 10:23:48 AM10/15/09
to
Hello Tim,


$strGroupfqdn = "<group DN>"
$strMyUser = [ADSI]"LDAP://$strGroupfqdn"
$strMyUser.PSBase.Properties.mail.clear()
$strMyUser.PSBase.CommitChanges()

Karl


Tim Munro

unread,
Oct 16, 2009, 8:19:55 AM10/16/09
to
Excellent, thanks Karl.

"Karl Mitschke" <karlmi...@somestate.gov> wrote in message
news:d66cd4c215de68...@msnews.microsoft.com...

Karl Mitschke

unread,
Oct 16, 2009, 10:32:54 AM10/16/09
to
Hello Tim,

Glad I could help

Karl

Karl


0 new messages