This was a request of one of our departments on how to check the last login time of their users. As you prepare to migrate your department to Exchange 2010, you might find this useful to help determine if there are any accounts that might be left out of the migration.
If you do decide to leave an account out of the migration, disable the mailbox and move the user to the LostUsers OU so that our scripts may remove them from AD.
get-mailbox -OrganizationalUnit "ou=YOURORGHERE,ou=UNT,DC=unt,DC=ad,DC=unt,DC=edu" -DomainController GABUNTDC01.unt.ad.unt.edu | Get-MailboxStatistics |fl DisplayName, LastLogonTime >> c:\YOURFILENAMEHERE.txt