I
Indra
Hi
I am importing mails from MSG files to my custom folder using Redemption
library. Import is working fine. But when I try to open the imported item, I
am not able to see “From†field. It shows only “TOâ€, “CC†and “BCCâ€.
Code Snippet (for import):
=====================================================
Dim sItem
Dim oItem As Outlook.MailItem
Dim iGateMails As MAPIFolder
Dim inboxFolder As MAPIFolder
Dim ns As NameSpace
Set ns = Application.GetNamespace("MAPI")
Set iGateMails = ns.Folders.Item("XXXXXXX")
Set inboxFolder = iGateMails.Folders.Item("Inbox")
'Application.Session.GetDefaultFolder(OlDefaultFolders.olFolderInbox)
For i = 1 To 52
Set sItem = CreateObject("Redemption.SafeMailItem")
Set oItem =
Application.Session.GetDefaultFolder(OlDefaultFolders.olFolderInbox).Items.Add(OlItemType.olMailItem)
sItem.Item = oItem
strinfIle = "c:\temp\Test" & i & ".eml"
sItem.Import strinfIle, rdoSaveAsType.olRFC822 'olMSG, olRFC822 and
olTNEF formats are supported
sItem.Save
sItem.Move inboxFolder
Next i
=====================================================
How to show “From†field for the imported items in my custom folder?
Regards
Indra
I am importing mails from MSG files to my custom folder using Redemption
library. Import is working fine. But when I try to open the imported item, I
am not able to see “From†field. It shows only “TOâ€, “CC†and “BCCâ€.
Code Snippet (for import):
=====================================================
Dim sItem
Dim oItem As Outlook.MailItem
Dim iGateMails As MAPIFolder
Dim inboxFolder As MAPIFolder
Dim ns As NameSpace
Set ns = Application.GetNamespace("MAPI")
Set iGateMails = ns.Folders.Item("XXXXXXX")
Set inboxFolder = iGateMails.Folders.Item("Inbox")
'Application.Session.GetDefaultFolder(OlDefaultFolders.olFolderInbox)
For i = 1 To 52
Set sItem = CreateObject("Redemption.SafeMailItem")
Set oItem =
Application.Session.GetDefaultFolder(OlDefaultFolders.olFolderInbox).Items.Add(OlItemType.olMailItem)
sItem.Item = oItem
strinfIle = "c:\temp\Test" & i & ".eml"
sItem.Import strinfIle, rdoSaveAsType.olRFC822 'olMSG, olRFC822 and
olTNEF formats are supported
sItem.Save
sItem.Move inboxFolder
Next i
=====================================================
How to show “From†field for the imported items in my custom folder?
Regards
Indra