Hi all
I'm working on a script that should remove a specific user from all shared mailboxes in Office 365.
So far I have created this:
foreach ($Alias in Get-Mailbox -RecipientTypeDetails SharedMailbox) {
Remove-MailboxPermission -Identity $Alias -User "User@doamin.dk" -AccessRights FullAccess
}
But i'm getting an error.
Cannot process argument transformation on parameter 'Identity'.
Any of you guys that can help me out.
Best Regards
Chris