Export-Mailbox Command Usage Examples

Export-mailbox -Identity ERKAN_SEZGIN -pstFolderPath D:\PST\

This command will export ERKAN_SEZGIN mail items to the pst file.

Export-mailbox -Identity ERKAN_SEZGIN -TargetMailbox ADMIN -TargetFolder Data

Mail Items will be copied to the Data Folder in another user mailbox

Get-Mailbox -Database DB01 | Export-Mailbox -TargetMailbox ADMIN
-TargetFolder VirusData -SubjectKeywords "mustdelete" -DeleteContent

-StartDate
-EndDate
Note:date parameters depends on your computer regional settings.

-RecipientKeywords erkan.sezgin@contoso.com

Export-Mailbox -Identity contoso\erkan.sezgin -TargetMailbox ADMIN -TargetFolder
MyData -ContentKeywords "bodyContent" -AttachmentFilenames "*FinanceList*" -StartDate
"01/01/2007 00:00:01" -RecipientKeywords userX@contoso.com

This example exports all items from the mailbox user contoso\erkan.sezgin that meet the following criteria:
* Contain the keyword "bodyContent" in the message body or in the content of an
attachments.
* Have an attachments that is named *FinanceList*.
* Are dated later than 01/01/2007 at 00:00:01 A.M.
* Have userX@contoso.com as one of the recipients.