Problem accessing trusted object from Outlook namespace

M

Martin Gerhold

Yesterday I was successfully accessing mail items without getting the 'address
book' warning (which has only started occurring recently):

Set item = Application.ActiveExplorer.Selection.item(1)
strEntryID = item.EntryID
Set olNS = Application.GetNamespace("MAPI")
Set oMail = olNS.GetItemFromID(strEntryID)
....
do stuff with oMail, e.g. MsgBox oMail.Body

(based on finding links such as
http://www.wiredbox.net/Forum/Thread152076_Problem_running_a_VBA_script_from_an_Outlook_rule.aspx
via google)

Today this no longer works - the warning pops up every time. Anyone have any
ideas what may have changed?

Note that this is in a corporate environment, with macro security locked to
'high', and self-certification of macros is required. Outlook 2003
(11.8206.8221) SP3.

Any ideas gratefully received, Martin
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads


Top