No. You would just need some event code to monitor your network Inbox for new messages, and automatically move them to the mailbox you keep in the local PST file. For example, the following code will move emails from the Inbox of a mailbox named "Tiger Chen" to the Inbox in a mailbox called "Personal Items" which would be a PST mailbox on your local drive.
(placed in ThisOutlookSession module)
Private WithEvents MyItems As Outlook.Items
Private Sub Application_Startup()
Dim objNS As Outlook.NameSpace
Set objNS = GetNamespace("MAPI")
Set MyItems = objNS.Folders("Mailbox - Tiger Chen").Folders("Inbox").Items
End Sub
Private Sub MyItems_ItemAdd(ByVal item As Object)
Dim Msg As Outlook.MailItem
Dim MyFolder As Outlook.MAPIFolder
If TypeOf item Is Outlook.MailItem Then
Set Msg = Item
Set MyFolder = objNS.Folders("Mailbox - Personal Items"). _
Folders("Inbox")
Msg.Move MyFolder
End If
End Sub
Originally Posted by
Tiger Chen
I would like it automatically. Is it the code for Exchange Server? I cannot image we can do it at client end.