New mail.box file

I have had to create a new mail.box file after the previous one stopped routing mail. I have renamed the old and created a new one. How can I copy mail from the old mail.box to the new ? When I try cutting and pasting the “From” field is changed to my name.Any help is appreciated.\Paul

Subject: New mail.box file

Hi,

I seem to remember that in earlier versions you could work around this by using an agent to copy the documents across. So perhspa something like this might do the trick:

Sub Initialize

Dim session As New NotesSession

Dim currDb As NotesDatabase

Dim mailBoxDb As New NotesDatabase("","")

Dim docCol As NotesDocumentCollection

Dim doc As NotesDocument

Dim nextDoc As NotesDocument



'// Get the current database

Set currDb = session.CurrentDatabase



'// Open the MailBox

Call mailBoxDb.Open(currDb.Server,"Mail.Box")

If mailBoxDb.IsOpen = True Then

	'// Step through all selected documemnts

	Set docCol = currDb.UnprocessedDocuments

	Set doc = docCol.GetFirstDocument

	Do While Not (doc Is Nothing)

		Set nextDoc = docCol.GetNextDocument(doc)

		

		'// Copy the document across

		Call doc.CopyToDatabase(mailBoxDb)

		

		Set doc = nextDoc

	Loop

	

End If

End Sub

I have ust written the above and have not even tried to save it, but I think it is along the right lines.

Hope this helps.

Cheers

Alan