Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Here is the scenario that I am in and am stuck on how to get this the correct way.

What I'm looking for is a syntax that will provide me with statistics on what users have emailed "Sent" for the day.

I would like to know get information on what all users of a specific distribution group has emailed for the day.

I have tried the following to no avail. Get-Mailbox | Get-MailboxFolderStatistics -FolderScope SentItems | Where {$_.ItemsInFolder -gt 0} | -Start "06/14/2012 9:00AM" -End "06/14/2012 5:00PM" | Sort-Object -Property ItemsInFolder -Descending | select-object Identity,ItemsInFolder | export-csv c:\test.txt

Get-MessageTrackingLog -Start "06/14/2012 9:00AM" -End "06/14/2012 5:00PM" -Sender "" | measure-object - This one will only work on specified users, but I need to check the whole group.

If anyone could help me out. Thank you!!!

share|improve this question

Try this script out. It grabs the member SMTP addresses from a Distribution Group and runs them against the message tracking logs to get a count for the time range for each member's e-mail address :

Import-Module C:\Temp\Exchange.psm1
$array = @()
$emails = Get-DistributionGroupMember "<group name>" | % {$_.primarysmtpaddress}
$start = "7/11/2012 9:00:00 AM"
$end = "7/11/2012 5:00:00 PM"
ForEach ($email in $emails) {
    $count = get-messagetrackinglog -Sender $email -EventID "SEND" -Start $start -End $end | measure-object | Select Count
    $array += @(,$email,$count)
ForEach($row in $array)
    Write-Host $row
share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.