Eric F
Posts: 1
Joined: 2005-06-19
|
I have recently purchased Add-in Express .NET, and really enjoy it. However, even after playing with the samples all weekend i still can not retrieve any other MAPI properties other then the PR_BODY and such that i saw in the sample. I have spent all weekend searching the internet, and on MSDN database. But to no avail, i still can't get it to work.
For example: PR_MESSAGE_DELIVERY_TIME
Could you please give me some sample code or point me in the right direction. This is urgent, i need to finish this project.
Thank you very much!
-Eric |
|
Sergey Grischenko
Add-in Express team
Posts: 7233
Joined: 2004-07-05
|
Hi Eric.
I suppose you have ran our ADX Toys for Outlook. If so, you can add the following code to the ADX Toys project to obtain the delivety time of a message:
private class MAPI
{
...
public const uint PT_SYSTIME = 64;
public const uint PR_MESSAGE_DELIVERY_TIME = ((((uint)(0x0E06))<<16)|((uint)(64)));
...
}
private void btnShowIH_Click(object sender)
{
...
//Put this code into the btnShowIH_Click procedure after setting the
//iheader variable to the message header.
MAPI.HrGetOneProp(unk, MAPI.PR_MESSAGE_DELIVERY_TIME, out pPropValue);
propValue = (MAPI.SPropValue)Marshal.PtrToStructure(pPropValue, typeof(MAPI.SPropValue));
DateTime deliveryTime = DateTime.FromFileTime(propValue.Value);
iheader += "\r\n";
iheader += "Delivery Time is " + deliveryTime.ToString();
...
} |
|