MAPIStoreAccessor initialzation

Add-in Express™ Support Service
That's what is more important than anything else

MAPIStoreAccessor initialzation
MAPIStoreAccessor initialzation throws Exception on Outlook Startup 
srinivas prrabhu




Posts: 2
Joined: 2011-05-29
I've problem where ADXMAPIStoreAccessor.Initialize(false) throws error.
I have found another threads in the forums related to Initialize but couldn't find any reason for it.

The MAPIStoreAccessor is not initialized, throws an exception in OutLook 2003. this problem is observed when eDoc-DM plugin is added to the outlook.

1. What could be the possible reasons for the MAPIStoreAccessor initialization problem ?
2. Actually with my plugin i don't see any problem, but problem comes only when we eDoc-DM plugin is added to the outlook ?
3. Can one plugin impact the functionality of another plugin ?
4. If the MAPIStoreAccessor initialization throws Exception, is it still possible that the stores that are properly loaded works ?
5. Is it mandatory that MAPIStoreAccessor initialization is done in AddinStartupComplete ?


sample lines of code

AddinExpress.MAPI.ADXMAPIStoreAccessor MAPIAccessor = new AddinExpress.MAPI.ADXMAPIStoreAccessor();
MAPIAccessor.Initialize(false);
transport=MAPIAccessor.GetProperty(msg,ADXMAPIPropertyTag._PR_TRANSPORT_MESSAGE_HEADERS).ToString();

Following are the error messages shown.
m_MAPIAccessor_OnMsgStoreError Entry
2009-08-05 10:26:55.4062 ERROR: OUTLOOK 2884 1 m_MAPIAccessor_OnMsgStoreError MAPI Data Store Error: id=2, store=Unknown, reason=CannotOpen

m_MAPIAccessor_OnClientError Client Error in MAPI; exception caught System.NullReferenceException: Object reference not set to an instance of an object.
at MAPIWrapper.Subscribe(MAPIWrapper* , UInt32 eventMask, Int32 address, Int32 callbackAddress)
at AddinExpress.MAPI.ADXMAPIStoreAccessor.Initialize(Boolean CreateNewSession)

Our environment:
Version of Windows is Windows XP SP3
Microsoft Office Outook version is 2003 (11.8325.8333) SP3
Hummingbird (open text) version is 5.2 cu5
Visual Studio 2008
Addin Express 2010



Thanks in advance,
Srinivas
Posted 29 May, 2011 09:16:04 Top
Eugene Astafiev


Guest


Hi Srinivas,

1. The cause of the issue you faced with may be various.
2. It looks like the eDoc-DM is the cause of the issue you faced with.
3. Sure!
4. Yep.
5. Nope. You can initialize the component in any event handler of your add-in. However, please note that you need to be logged in Outlook before you try to initialize it.

Did you try to pass true to the Initialize method of the MAPI Store Accessor? Does it help?
Posted 30 May, 2011 12:18:32 Top
srinivas prrabhu




Posts: 2
Joined: 2011-05-29
Hi Eugene,

Thanks so much for your reply.

Yes, i've tried passing true to the Initialize method of the MAPI Store Accessor, but it didn't help.

If i delete the eDoc-DM folder and unchecked the e-Doc-DM plugin then it works fine, so i'm not sure how eDoc-DM is creating the problem.

My Observation is in Outlook => data file management we can see that the file name is "not available" for the eDoc DM, the mails are stored in the server/exchange, could this be the reason Initialize failure?

Thanks,
Srinivas
Posted 31 May, 2011 00:22:24 Top
Eugene Astafiev


Guest


Hi Srinivas,

My Observation is in Outlook => data file management we can see that the file name is "not available" for the eDoc DM, the mails are stored in the server/exchange, could this be the reason Initialize failure?


Yep. You are on the right avenue. The eDoc-DM add-in adds a custom store to the profile which can't be opened by the MAPI Store Accessor component. Please try to use Redemption instead.
Posted 31 May, 2011 05:32:47 Top