To set the sharing permission for you, please refer the steps below,

1), connect to Exchange Online through PowerShell as administrator.

2), run Get-Mailbox to get the mailboxes you want to modify, you can use different filter to pick the user you want to configure, for example, Get-Mailbox -RecipientTypeDetails UserMailbox will return all user mailboxes(no shared mailboxes, room mailboxes and discovery mailbox). For detailed information, you can run Get-Help Get-Mailbox -Detailed | More.

3), prepare a text file, save the following content in 4 lines, you can customize the first line to the filter you want to set,

foreach($user in (Get-Mailbox -RecipientTypeDetails UserMailbox)) {

$cal = $user.alias+”:Calendar”

Add-MailboxFolderPermission -Identity $cal -User your@domain.com -AccessRights Reviewer

}

4), save the text file to d:exopscal.ps1 file, then run d:exopscal.ps1 in PowerShell. All the calendars’ permission in the mailboxes defined in the first line will be changed to full detailed.

Removing is this –

Remove-MailboxFolderPermission -Identity $cal -User your@domain.com

Leave a Reply