Answers for "get shared mailbox powershell exchange 2010"

0

get shared mailbox powershell exchange 2010

$Mailboxes = Get-Mailbox -RecipientTypeDetails SharedMailbox
foreach ($Mailbox in $Mailboxes)
{
$Mailbox | Add-Member -MemberType “NoteProperty” -Name “MailboxSizeMB” -Value ((Get-MailboxStatistics $Mailbox).TotalItemSize.Value.ToMb())
$Mailbox | Add-Member -MemberType “NoteProperty” -Name “ItemCount” -Value ((Get-MailboxStatistics $Mailbox).ItemCount)
}
$Mailboxes | Sort-Object MailboxSizeMB -Desc | Select DisplayName,PrimarySMTPAddress,MailboxSizeMB,ItemCount,SamAccountName | Export-Csv -NoType “C:\Mailboxessize.csv”
Posted by: Guest on July-20-2020

Code answers related to "Shell/Bash"

Browse Popular Code Answers by Language