ExMerge is probably one of the exchange administrators most used tools, but is a pain to use if you are working with large mailboxes, as it uses Outlook 2000 PST files which corrupt when they reach 2Gb. ExMerge also does not work with Outlook 2003 PST's ... I'm sure (and really hope ) this will be addressed in Exchange 2007.

So, if you find yourself in a situation where you want to move the contents of a 10Gb mailbox to a another mailbox, and you don't have any tools such as Mail Attender for Exchange that can do it for you, you have to run ExMerge several times using date ranges to ensure the PST's don't exceed the 2Gb limit.

In my particular situation, I have a folder in a mailbox containing 300,000 items that I want to move to a journal mailbox to be picked up by a mail archiving system. I can't move them across manually using Outlook, because it fails when you drag and drop more than 2000 items, and trying to navigate around such a massive mailbox anyway is too slow to mention.

One of the vb experts here helped me write a macro to complete this task. It can be run from the Visual Basic Editor in Outlook. To run it use Tools - Macros - Visual Basic Editor, and click Yes to enable macros. Modify the code below so that Mailbox 1 and Mailbox 2 match the names of the mailboxes you are working on. Mailbox 1 is the source mailbox, and Mailbox 2 is the destination. You must then open both of these mailboxes in your Oulook profile before you start the macro.

Sub move_messages()

Dim objExch2003 As Outlook.MAPIFolder, objErrors As Outlook.MAPIFolder, objInbox As Outlook.MAPIFolder, objJournal As Outlook.MAPIFolder, objJournalInbox As Outlook.MAPIFolder
Dim objNS As Outlook.NameSpace, intcount As Integer, i As Integer, objMailItem As Object
Set objNS = Application.GetNamespace("MAPI")
Set objExch2003 = objNS.Folders("Mailbox - Mailbox 1")
Set objJournal = objNS.Folders("Mailbox - Mailbox 2")
Set objInbox = objExch2003.Folders("Inbox")
Set objJournalInbox = objJournal.Folders("Inbox")
Set objErrors = objInbox.Folders("Errors")

Do While objErrors.Items.Count > 0

For i = 100 To 1 Step -1
Set objMailItem = objErrors.Items(i)
objMailItem.Move objJournalInbox
Next

Loop

End Sub

After you start it your Outlook will appear to crash - this is normal and it is really working in the background. You can use ESM to watch the number of items decrease in Mailbox 1 and increase in Mailbox 2.

Technorati Tags: , , , , ,