Unable to set property using ADXMAPIStoreAccessor on new object?

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

Unable to set property using ADXMAPIStoreAccessor on new object?
 
David Thompson


Guest


Hello,

I was trying to use ADXMAPIStoreAccessor to create a custom property, but the SetProperty method returns 1 rather than zero. Also, the GetMapiObject method returns null.

The object I am working with is a new object - that is, the user has just clicked New->Mail Message, so the object has never been saved.

Before I go digging very deep to see what is wrong with my code, can you tell me whether I should be able to use MAPI functions on objects that are probably not in the MAPI store yet?

Thanks!

David
Posted 20 May, 2009 12:09:26 Top
Eugene Astafiev


Guest


Hello David,

The object I am working with is a new object - that is, the user has just clicked New->Mail Message, so the object has never been saved.


You need to save it first. A new message doesn't contain the Entry ID property.

Before I go digging very deep to see what is wrong with my code, can you tell me whether I should be able to use MAPI functions on objects that are probably not in the MAPI store yet?


No, you need to save a message.
Posted 20 May, 2009 12:19:33 Top
David Thompson


Guest


Thanks for the quick response! That was very helpful.
Posted 20 May, 2009 12:21:56 Top
Eugene Astafiev


Guest


You are welcome, David.
Posted 20 May, 2009 12:43:19 Top