J
John
Hi
I am using the following code to search for an email message with id myID;
Dim SentFld As Outlook.MAPIFolder
Dim Email As Outlook.MailItem
Dim I As Integer
OutlookApp = New Outlook.Application
SentFld =
OutlookApp.Session.GetDefaultFolder(Outlook.OlDefaultFolders.olFolderSentMai
l)
iCount = SentFld.Items.Count
Email = CType(SentFld.Items.Item(1), Outlook.MailItem)
Email.UserProperties.Add("EmailID", Outlook.OlUserPropertyType.olText, True)
Email = SentFld.Items.Find("[EmailID]=""" & myID & """")
The problem is that the find is very slow. Is there a faster way to search
for emails with specific user defined ids?
Thanks
Regards
I am using the following code to search for an email message with id myID;
Dim SentFld As Outlook.MAPIFolder
Dim Email As Outlook.MailItem
Dim I As Integer
OutlookApp = New Outlook.Application
SentFld =
OutlookApp.Session.GetDefaultFolder(Outlook.OlDefaultFolders.olFolderSentMai
l)
iCount = SentFld.Items.Count
Email = CType(SentFld.Items.Item(1), Outlook.MailItem)
Email.UserProperties.Add("EmailID", Outlook.OlUserPropertyType.olText, True)
Email = SentFld.Items.Find("[EmailID]=""" & myID & """")
The problem is that the find is very slow. Is there a faster way to search
for emails with specific user defined ids?
Thanks
Regards