add msExchHideFromAddressLists to a disabled user AD attitude.
Set-ADUser username -Add @{msExchHideFromAddressLists=”TRUE”}
wait for AD Sync…
check O365 mailbox setting
Get-Recipient [email protected] |fl HiddenfromaddresslistsEnabled
exchange (active mailbox)
Set-Mailbox -Identity [email protected] -HiddenFromAddressListsEnabled $True
more details: