Overview
Examples
Screenshots
Comparisons
Applications
Download
Documentation
Tutorials
Bazaar
Status & Roadmap
FAQ
Authors & License
Forums
Funding Ultimate++
Search on this site











SourceForge.net Logo

MAPIMessage

 

class MAPIMessage : public MAPIObject

Outlook email message.

 

 

Constructor detail


 

MAPIMessage()

Default constructor.

 

Public Method List


 

bool IsUnread()

Returns true if message is unread.

 


 

bool MarkAsRead(bool bRead = true)

Marks message ar read or unread depending the value of bRead.

 


 

bool Create(MAPIEx &mapi, MAPIFolder &folder, int nPriority = IMPORTANCE_NORMAL, bool bSaveToSentFolder = true)

Creates the message using MAPIEx mapi, in folder folder, with priority nPriority , and labeled as "delete after submit" if bSaveToSentFolder is false.

Valid priorities in nPriority are IMPORTANCE_NORMAL, IMPORTANCE_HIGH or IMPORTANCE_LOW.

 


 

int ShowForm(MAPIEx* pMAPI, MAPIFolder &folder)

Opens the email window form using MAPIEx pMAPI, in folder folder.

Returns false on failure, IDOK on success or close existing messages and IDCANCEL on close new messages.

 


 

bool Send()

Sends the email.

 


 

String GetHeader()

Returns the message header.

 


 

String GetSenderName()

Returns the sender name.

 


 

String GetSenderEmail()

Returns the sender email.

 


 

String GetSubject()

Returns the message subject.

 


 

Time GetSubmitTime()

Returns the message submit time.

 


 

Time GetReceivedTime()

Returns the message received time.

 


 

Time GetLastModificationTime()

Returns the message last modification time.

 


 

Time GetCreationTime()

Returns the message creation time.

 


 

String GetTo()

Returns the "to" email display addresses.

 


 

String GetCC()

Returns the "cc" email display addresses.

 


 

String GetBCC()

Returns the "bcc" email display addresses.

 


 

int GetSensitivity()

Returns the message sensitivity.

 


 

int GetMessageStatus()

Returns the message status.

 


 

int GetPriority()

Returns the message priority.

 


 

DWORD GetSize()

Returns the message size.

 


 

bool GetRecipients()

Gathers message recipients. To be called before GetNextRecipient().

 


 

bool GetNextRecipient(String& strName, String& strEmail, int& nType)

Gets next recipient data like name in strName, email in strEmail and type in nType.

Valid types are:

MAPI_TO: Recipient is a primary (To) recipient.

MAPI_CC: Recipient is a carbon copy (CC) recipient.

MAPI_BCC: Recipient is a blind carbon copy (BCC) recipient.

 


 

String GetReplyTo()

Gets the recipients that are to get a reply

 


 

bool AddRecipient(const String &email, int nType=MAPI_TO, const char* szAddrType=NULL)

Add a new recipient with email and type nType.

Valid types are:

MAPI_TO: Recipient is a primary (To) recipient.

MAPI_CC: Recipient is a carbon copy (CC) recipient.

MAPI_BCC: Recipient is a blind carbon copy (BCC) recipient.

 


 

void SetSubject(const String &subject)

Sets message subject in subject.

 


 

void SetSender(const String &senderName, const String &senderEmail)

senderName senderEmail.

 


 

bool SetReceivedTime(const Time &tm)

Sets message received time in tm.

 


 

bool SetSubmitTime(const Time &tm)

Sets message submit time in tm.

 


 

bool SetReadReceipt(bool bSet = true, String szReceiverEmail = Null)

bSet szReceiverEmail.

 


 

bool SetDeliveryReceipt(bool bSet = true)

Sets delivery receipt in bSet.

 


 

bool MarkAsPrivate()

Mark message as private.

 


 

bool SetMessageStatus(int nMessageStatus)

Sets message status in nMessageStatus.

 


 

bool SaveToFile(const String &fileName)

Saves message to .msg file in fileName. Returns true if there is no problem.

 

 

Do you want to contribute?