I have an access database which stores the details of a email including send date, contacts, message body, entryid, conversationid, etc but I based on my research the entryid changes if the email is moved. Well our emails get moved around a lot since its a shared mailbox. Therefore I was trying to find a solution to search outlook for a unique id that doesnt change. Everything I have found on this forum and others points to the message ID. The issue I am coming across is to get the message id you need to use the following code:
.PropertyAccessor.GetProperty("http://schemas.microsoft.com/mapi/proptag/0x007D001F")
which returns a lot of information and not just the message-ID. The other issue I am coming across is I am unsure of the best method to search through the outlook mailboxes for this message-id. Is my only option to loop through all emails and get their properties and extract the message-id and compare to the one I am search for?