Share via


Exchange 2010 Adding Mailbox Calendar permissions using PowerShell

Consider the following scenario

We have Students and Teachers located on the same Exchange 2010 server.

Default calendar permissions is set to Free / Busy time

A request has come from the teachers department,

All teachers would like to have Reviewer permissions to each others calendar folders.

Now

What is already prepared in this Exchange environment is that all Teachers have their CustomAttribute1 set to Teacher

And a Mail Universal Security Group already exists with the primary SMTP address Teachers@repro.com

To achieve the teachers request. All we need to do is to run the following powershell command.

Get-mailbox -Filter {(CustomAttribute1 -eq "Teacher")} | ForEach-Object {Add-MailboxFolderPermission $_":\Calendar" -User Teachers@repro.com -AccessRights Reviewer}

Permissions needed.

Mailbox folder permissions

Organization Management

Recipient Management

Help Desk

We are done !!!

To remove the permissions we just added.

Get-mailbox -Filter {(CustomAttribute1 -eq "Teacher")} | ForEach-Object {Remove-MailboxFolderPermission $_":\Calendar" -User Teachers@repro.com}

 

Add-MailboxFolderPermission
https://technet.microsoft.com/en-us/library/dd298062.aspx

Comments

  • Anonymous
    September 15, 2010
    Hi I have a sample code $users=Get-Mailbox -resultsize Unlimited ForEach ($user in $users)               {Set-MailboxFolderPermission -Identity $user":calendar" -user Default -AccessRights Reviewer} which changes this for all user mailboxes default permissions to reviewer. Do you think there are any pros/cons against this approach? thanks

  • Anonymous
    September 27, 2010
    The comment has been removed

  • Anonymous
    April 11, 2011
    @Teun van Hemert i have the same problem. the users can reach the calendar via owa,but can NOT do it via ms outlook

  • Anonymous
    January 11, 2012
    Hey guys If you read social.technet.microsoft.com/.../bcc000df-444e-474c-86db-a7ec55b3d60f you will find the answer to your question :)

  • Anonymous
    October 06, 2013
    This is an easier way to use this command. Get-content C:tempCalendar.txt | ForEach-Object {Add-MailboxFolderPermission $_":Calendar" -User Teachers@repro.com -AccessRights Reviewer} fill the Calendar txt file with the aliases of users on which the Calender permissions must be set.