Hi Readers,

Recently we have got a requirement to provide one group access to all Resource Calendars so that they can book out of policy requests.

They don't want any delegate appprovals therefore we came up with this approach, created a group of the users that need this kind of feature,

Created the script that will assign Author access to all Resource Calendars, Created a process document on how to book the room directly in

Resource mailbox calendar.

 

Download & extract the script from above....

Change the below variables accordingly & schedule the batch file..

$access = "Author"     

$usrgp =  "AllRoomsAuthorAccess"  # group Name that you want to use

 

Replace the ExchangeServer Name... 

$Session = New-PSSession -ConfigurationName Microsoft.Exchange -ConnectionUri http://ExchangeServer/PowerShell/ -Authentication Kerberos

 

You can use this script to apply any of the below permissions

# None 

# Owner

# PublishingEditor

# Editor

# PublishingAuthor 

# Author  

# NonEditingAuthor   

# Reviewer

# Contributor

 

On first run you should change the condition from $_.WhenMailboxCreated -ge $days to $_.WhenMailboxCreated -le $days so that permissions are applied to mailboxes that are already in the enviornment, after that you can change it back to what it is $_.WhenMailboxCreated -ge $days to apply permissions on newly created mailboxes.

 

 More info can be found at http://msexchange.me/2015/05/14/add-group-access-to-mailboxes-resources/

PowerShell
Edit|Remove
##############################################################################       Author: Vikas Sukhija#       Reviewer:    #       Date: 04/06/2015#       Update: #    Description: Add group as Author, reviewer or other access to #    ALL Rooms/Equipment resources# None # Owner# PublishingEditor# Editor# PublishingAuthor # Author  # NonEditingAuthor   # Reviewer# Contributor######################################################################################################Define Variables####################################$access = "Author"# Vaules can be anything from above$usrgp =  "AllRoomsAuthorAccess"$days = (get-date).adddays(-1) 
$limit = (Get-Date).AddDays(-60) #for log recycling$date = get-date-format d 
$date = $date.ToString().Replace(“/”, “-”) 
$time = get-date-format t 
 
$time = $time.ToString().Replace(":""-"$time = $time.ToString().Replace(" """) 
 
$path = ".\logs\" 
$output1 = ".\logs\" + "Addaccess_" + $date + "_" + $time + "_.log" 
$output2 = ".\logs\" + "Powershell_" + $date + "_" + $time + "_.log" 
 
 
###################### Add Exchange Shell####################################<#If ((Get-PSSnapin | where {$_.Name -match "Microsoft.Exchange.Management.PowerShell.E2010"}) -eq $null) 
{ 
    Add-PSSnapin Microsoft.Exchange.Management.PowerShell.E2010 
}#>$Session = New-PSSession -ConfigurationName Microsoft.Exchange -ConnectionUri http://ExchangeServer/PowerShell/-Authentication Kerberos 
import-pssession $sessionstart-transcript-Path $output2########################Get all Rooms/Equipment mailboxes####################$Resources = Get-Mailbox -resultsize unlimited | where{($_.RecipientTypeDetails -like "RoomMailbox"-or ($_.RecipientTypeDetails -like "EquipmentMailbox")} 
 
if ($Resources){ 
 
$Resources|foreachif($_.WhenMailboxCreated -ge $days){ 
$Name = $_.primarysmtpaddress 
$now = get-date-Format t 
Write-host "Processing ...........$Name"-foregroundcolor Green 
 
Add-MailboxFolderPermission -identity ([string]$Name+":\Calendar"-User $usrgp-AccessRights $accessADD-content$output1"$now ...processed ..$Name" 
 } 
} 
} 
 
########################Recycle logs ######################################Get-ChildItem-Path $path| Where-Object {   
$_.CreationTime -lt $limit } |Remove-Item-recurse -Force  
 
 
stop-transcript###########################################################################

 

 

Regards
Sukhija Vikas

http://msexchange.me