SHARE
TWEET

GetUserFolders.ps1

a guest Nov 15th, 2012 233 Never
  1. param([string]$user)
  2. if ($user -eq ""){$user = read-host "Please enter user"}
  3. get-mailbox $user |Get-MailboxFolderStatistics | where {$_.ItemsInFolder -gt 0} |sort-object -descending foldersize | ft folderpath, itemsinfolder, @{label="Folder Size(MB)";expression={$_.FolderSize.ToMB()}} -autosize
  4. get-mailboxstatistics $user | ft DisplayName,@{label= "Total Size (MB)";expression={$_.TotalItemSize.Value.ToMB()}}, ItemCount, DatabaseName
RAW Paste Data
Top