Sophie

Sophie

distrib > Fedora > 14 > x86_64 > by-pkgid > 1760bbde8794f5b323299b3a051b5bd6 > files > 81

openchange-devel-0.9-11.fc14.x86_64.rpm

<html>
  <head>
    <title>MAPIClientLibraries 0.9 API Documentation</title>
    <link href="doxygen.css" rel="stylesheet" type="text/css"/>
    <link href="apidocs.css" rel="stylesheet" type="text/css"/>
  </head>
  <body>
    <div id="website">
    <div class="header"></div>
      <div id="middle_side">
	<div id="right_side_home">
<!-- Generated by Doxygen 1.7.1 -->
<div class="navigation" id="top">
  <div class="tabs">
    <ul class="tablist">
      <li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
      <li><a href="pages.html"><span>Related&nbsp;Pages</span></a></li>
      <li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
      <li class="current"><a href="files.html"><span>Files</span></a></li>
      <li><a href="examples.html"><span>Examples</span></a></li>
    </ul>
  </div>
  <div class="tabs2">
    <ul class="tablist">
      <li><a href="files.html"><span>File&nbsp;List</span></a></li>
      <li><a href="globals.html"><span>Globals</span></a></li>
    </ul>
  </div>
</div>
<div class="header">
  <div class="summary">
<a href="#func-members">Functions</a>  </div>
  <div class="headertitle">
<h1>libmapi/IMAPIFolder.c File Reference</h1>  </div>
</div>
<div class="contents">

<p>Folder related functions.  
<a href="#_details">More...</a></p>
<code>#include &lt;<a class="el" href="libmapi_8h.html">libmapi/libmapi.h</a>&gt;</code><br/>
<table class="memberdecls">
<tr><td colspan="2"><h2><a name="func-members"></a>
Functions</h2></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">_PUBLIC_ enum MAPISTATUS&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="IMAPIFolder_8c.html#adda493203e99475273c498c1f051bfd4">CopyFolder</a> (<a class="el" href="structmapi__object.html">mapi_object_t</a> *obj_folder, <a class="el" href="structmapi__object.html">mapi_object_t</a> *obj_src, <a class="el" href="structmapi__object.html">mapi_object_t</a> *obj_dst, char *NewFolderName, bool UseUnicode, bool WantRecursive)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">_PUBLIC_ enum MAPISTATUS&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="IMAPIFolder_8c.html#a03a3f5d51af0ce6d0a92a5d319326f93">CreateFolder</a> (<a class="el" href="structmapi__object.html">mapi_object_t</a> *obj_parent, enum FOLDER_TYPE ulFolderType, const char *name, const char *comment, uint32_t ulFlags, <a class="el" href="structmapi__object.html">mapi_object_t</a> *obj_child)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">_PUBLIC_ enum MAPISTATUS&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="IMAPIFolder_8c.html#aa121bcd38e1bf43350ecab96c8b46e84">CreateMessage</a> (<a class="el" href="structmapi__object.html">mapi_object_t</a> *obj_folder, <a class="el" href="structmapi__object.html">mapi_object_t</a> *obj_message)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">_PUBLIC_ enum MAPISTATUS&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="IMAPIFolder_8c.html#a616318752860658e5f5f376811cfd337">DeleteFolder</a> (<a class="el" href="structmapi__object.html">mapi_object_t</a> *obj_parent, <a class="el" href="mapi__object_8h.html#ac1033858b28ee56b5f4d1578c297b87e">mapi_id_t</a> FolderId, uint8_t DeleteFolderFlags, bool *PartialCompletion)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">_PUBLIC_ enum MAPISTATUS&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="IMAPIFolder_8c.html#a570002287fc409bfb451f4e35481c6a0">DeleteMessage</a> (<a class="el" href="structmapi__object.html">mapi_object_t</a> *obj_folder, <a class="el" href="mapi__object_8h.html#ac1033858b28ee56b5f4d1578c297b87e">mapi_id_t</a> *id_messages, uint32_t cn_messages)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">_PUBLIC_ enum MAPISTATUS&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="IMAPIFolder_8c.html#aa9fd00c745b4d7bb4ca4bc091a58caac">EmptyFolder</a> (<a class="el" href="structmapi__object.html">mapi_object_t</a> *obj_folder)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">_PUBLIC_ enum MAPISTATUS&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="IMAPIFolder_8c.html#a505af78b45a3299cea6c3c60eff4bb79">GetMessageStatus</a> (<a class="el" href="structmapi__object.html">mapi_object_t</a> *obj_folder, <a class="el" href="mapi__object_8h.html#ac1033858b28ee56b5f4d1578c297b87e">mapi_id_t</a> msgid, uint32_t *ulStatus)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">_PUBLIC_ enum MAPISTATUS&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="IMAPIFolder_8c.html#a01717e01f01cc28fdbfa503952af66e5">HardDeleteMessage</a> (<a class="el" href="structmapi__object.html">mapi_object_t</a> *obj_folder, <a class="el" href="mapi__object_8h.html#ac1033858b28ee56b5f4d1578c297b87e">mapi_id_t</a> *id_messages, uint16_t cn_messages)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">_PUBLIC_ enum MAPISTATUS&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="IMAPIFolder_8c.html#a2ae847258164d47c97d85be0263310e3">HardDeleteMessagesAndSubfolders</a> (<a class="el" href="structmapi__object.html">mapi_object_t</a> *obj_folder)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">_PUBLIC_ enum MAPISTATUS&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="IMAPIFolder_8c.html#a3b7f73870664d7fe2f94c29e35e3e2f2">MoveCopyMessages</a> (<a class="el" href="structmapi__object.html">mapi_object_t</a> *obj_src, <a class="el" href="structmapi__object.html">mapi_object_t</a> *obj_dst, <a class="el" href="structmapi__id__array.html">mapi_id_array_t</a> *message_id, bool WantCopy)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">_PUBLIC_ enum MAPISTATUS&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="IMAPIFolder_8c.html#a81405ca3fef5b65fae9d1cb33d315e08">MoveFolder</a> (<a class="el" href="structmapi__object.html">mapi_object_t</a> *obj_folder, <a class="el" href="structmapi__object.html">mapi_object_t</a> *obj_src, <a class="el" href="structmapi__object.html">mapi_object_t</a> *obj_dst, char *NewFolderName, bool UseUnicode)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">_PUBLIC_ enum MAPISTATUS&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="IMAPIFolder_8c.html#aa5c12f00fbd741c749ebe8c9c615fbd9">SetMessageStatus</a> (<a class="el" href="structmapi__object.html">mapi_object_t</a> *obj_folder, <a class="el" href="mapi__object_8h.html#ac1033858b28ee56b5f4d1578c297b87e">mapi_id_t</a> msgid, uint32_t ulNewStatus, uint32_t ulNewStatusMask, uint32_t *ulOldStatus)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">_PUBLIC_ enum MAPISTATUS&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="IMAPIFolder_8c.html#ada6550587b0ae4918a952ad8ac93704f">SetReadFlags</a> (<a class="el" href="structmapi__object.html">mapi_object_t</a> *obj_folder, uint8_t ReadFlags, uint16_t MessageIdCount, uint64_t *MessageIds)</td></tr>
</table>
<hr/><a name="_details"></a><h2>Detailed Description</h2>
<p>Folder related functions. </p>
<hr/><h2>Function Documentation</h2>
<a class="anchor" id="adda493203e99475273c498c1f051bfd4"></a><!-- doxytag: member="IMAPIFolder.c::CopyFolder" ref="adda493203e99475273c498c1f051bfd4" args="(mapi_object_t *obj_folder, mapi_object_t *obj_src, mapi_object_t *obj_dst, char *NewFolderName, bool UseUnicode, bool WantRecursive)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">_PUBLIC_ enum MAPISTATUS CopyFolder </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structmapi__object.html">mapi_object_t</a> *&nbsp;</td>
          <td class="paramname"> <em>obj_folder</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="structmapi__object.html">mapi_object_t</a> *&nbsp;</td>
          <td class="paramname"> <em>obj_src</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="structmapi__object.html">mapi_object_t</a> *&nbsp;</td>
          <td class="paramname"> <em>obj_dst</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">char *&nbsp;</td>
          <td class="paramname"> <em>NewFolderName</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">bool&nbsp;</td>
          <td class="paramname"> <em>UseUnicode</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">bool&nbsp;</td>
          <td class="paramname"> <em>WantRecursive</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">
<p>Copy a folder</p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>obj_folder</em>&nbsp;</td><td>the folder to copy </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>obj_src</em>&nbsp;</td><td>source object where the folder to copy is stored </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>obj_dst</em>&nbsp;</td><td>destination object where the folder will be copied </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>NewFolderName</em>&nbsp;</td><td>the new folder name in the destination folder </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>UseUnicode</em>&nbsp;</td><td>whether the folder name is unicode encoded or not </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>WantRecursive</em>&nbsp;</td><td>whether we should copy folder's subdirectories or not</td></tr>
  </table>
  </dd>
</dl>
<dl class="return"><dt><b>Returns:</b></dt><dd>MAPI_E_SUCCESS on success, otherwise MAPI error.</dd></dl>
<dl class="note"><dt><b>Note:</b></dt><dd>Developer may also call <a class="el" href="IUnknown_8c.html#a8237c7fc76377cb07f3f55920d6f20de">GetLastError()</a> to retrieve the last MAPI error code. Possible MAPI error codes are:<ul>
<li>MAPI_E_NOT_INITIALIZED: MAPI subsystem has not been initialized</li>
<li>MAPI_E_CALL_FAILED: A network problem was encountered during the transaction</li>
</ul>
</dd></dl>
<dl class="see"><dt><b>See also:</b></dt><dd><a class="el" href="proto_8h.html#a5d20a82a73d463254ac5e688f0f0cb0f">OpenFolder</a>, <a class="el" href="proto_8h.html#acf3f40942949ac192faaec2be8503992">MoveFolder</a> </dd></dl>

<p>References <a class="el" href="structmapi__provider.html#aa2906ad67334b042836f003e766d6d64">mapi_provider::ctx</a>, <a class="el" href="structmapi__session.html#a0d032340047573649b7527e660cac594">mapi_session::emsmdb</a>, <a class="el" href="emsmdb_8c.html#ae07f13624739ffff34e89ed3003a354e">emsmdb_transaction()</a>, <a class="el" href="cdo__mapi_8c.html#aa3c2b68912988f290961037c76478495">global_mapi_ctx</a>, <a class="el" href="mapi__object_8c.html#aa94645f34e6c4bf1c0631dffb0742676">mapi_object_get_handle()</a>, <a class="el" href="mapi__object_8c.html#ad4477e1e7c6dd8314638a9886b570209">mapi_object_get_id()</a>, <a class="el" href="mapi__object_8c.html#a96bfa7545b6e9ad350c42ba0abd07da8">mapi_object_get_logon_id()</a>, <a class="el" href="mapi__object_8c.html#ae5ef3137838fbc0c3eaedd7da99f8adc">mapi_object_get_session()</a>, <a class="el" href="mapicode_8h.html#a53da6d1258f2abd902930b6af1134d1c">OPENCHANGE_CHECK_NOTIFICATION</a>, and <a class="el" href="mapicode_8h.html#a72f77c7e5d097e7b47c57c0405070d0c">OPENCHANGE_RETVAL_IF</a>.</p>

</div>
</div>
<a class="anchor" id="a03a3f5d51af0ce6d0a92a5d319326f93"></a><!-- doxytag: member="IMAPIFolder.c::CreateFolder" ref="a03a3f5d51af0ce6d0a92a5d319326f93" args="(mapi_object_t *obj_parent, enum FOLDER_TYPE ulFolderType, const char *name, const char *comment, uint32_t ulFlags, mapi_object_t *obj_child)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">_PUBLIC_ enum MAPISTATUS CreateFolder </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structmapi__object.html">mapi_object_t</a> *&nbsp;</td>
          <td class="paramname"> <em>obj_parent</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">enum FOLDER_TYPE&nbsp;</td>
          <td class="paramname"> <em>ulFolderType</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const char *&nbsp;</td>
          <td class="paramname"> <em>name</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const char *&nbsp;</td>
          <td class="paramname"> <em>comment</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t&nbsp;</td>
          <td class="paramname"> <em>ulFlags</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="structmapi__object.html">mapi_object_t</a> *&nbsp;</td>
          <td class="paramname"> <em>obj_child</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">
<p>Create a folder</p>
<p>The function creates a folder (defined with its name, comment and type) within a specified folder.</p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>obj_parent</em>&nbsp;</td><td>the folder to create the new folder in </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>ulFolderType</em>&nbsp;</td><td>the type of the folder </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>name</em>&nbsp;</td><td>the name of the new folder </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>comment</em>&nbsp;</td><td>the comment associated with the new folder </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>ulFlags</em>&nbsp;</td><td>flags associated with folder creation </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>obj_child</em>&nbsp;</td><td>pointer to the newly created folder</td></tr>
  </table>
  </dd>
</dl>
<p>ulFlags possible values:</p>
<ul>
<li>MAPI_UNICODE: use UNICODE folder name and comment</li>
<li>OPEN_IF_EXISTS: open the folder if it already exists</li>
</ul>
<p>ulFolderType possible values:</p>
<ul>
<li>FOLDER_GENERIC</li>
<li>FOLDER_SEARCH</li>
</ul>
<dl class="return"><dt><b>Returns:</b></dt><dd>MAPI_E_SUCCESS on success, otherwise MAPI error.</dd></dl>
<dl class="note"><dt><b>Note:</b></dt><dd>Developers may also call <a class="el" href="IUnknown_8c.html#a8237c7fc76377cb07f3f55920d6f20de">GetLastError()</a> to retrieve the last MAPI error code. Possible MAPI error codes are:<ul>
<li>MAPI_E_NOT_INITIALIZED: MAPI subsystem has not been initialized</li>
<li>MAPI_E_CALL_FAILED: A network problem was encountered during the transaction</li>
</ul>
</dd></dl>
<dl class="see"><dt><b>See also:</b></dt><dd><a class="el" href="proto_8h.html#a5d20a82a73d463254ac5e688f0f0cb0f">OpenFolder</a>, <a class="el" href="proto_8h.html#a89202179905d03cb95b31b430790b9a1">DeleteFolder</a>, <a class="el" href="proto_8h.html#a364dcbce3198d58aa0ab6a813411bcbf">EmptyFolder</a>, <a class="el" href="proto_8h.html#a8237c7fc76377cb07f3f55920d6f20de">GetLastError</a> </dd></dl>

<p>References <a class="el" href="structmapi__provider.html#aa2906ad67334b042836f003e766d6d64">mapi_provider::ctx</a>, <a class="el" href="structmapi__session.html#a0d032340047573649b7527e660cac594">mapi_session::emsmdb</a>, <a class="el" href="emsmdb_8c.html#ae07f13624739ffff34e89ed3003a354e">emsmdb_transaction()</a>, <a class="el" href="cdo__mapi_8c.html#aa3c2b68912988f290961037c76478495">global_mapi_ctx</a>, <a class="el" href="mapi__object_8c.html#aa94645f34e6c4bf1c0631dffb0742676">mapi_object_get_handle()</a>, <a class="el" href="mapi__object_8c.html#a96bfa7545b6e9ad350c42ba0abd07da8">mapi_object_get_logon_id()</a>, <a class="el" href="mapi__object_8c.html#ae5ef3137838fbc0c3eaedd7da99f8adc">mapi_object_get_session()</a>, <a class="el" href="mapi__object_8c.html#af49c3130b8cb47f741ff652fc53c1364">mapi_object_init()</a>, <a class="el" href="mapi__object_8c.html#a6cad283dc5a1228734e816adb30aa53c">mapi_object_set_handle()</a>, <a class="el" href="mapi__object_8c.html#a87947ae1569ed162473811bb257922cb">mapi_object_set_id()</a>, <a class="el" href="mapi__object_8c.html#a845af67422945480121797b8a44ab14d">mapi_object_set_logon_id()</a>, <a class="el" href="mapi__object_8c.html#a373e9bd46155ea22e816fa66944f22a6">mapi_object_set_session()</a>, <a class="el" href="mapidefs_8h.html#a1cb4e3df7b73c2c92cb1498e680d49de">MAPI_UNICODE</a>, <a class="el" href="mapicode_8h.html#a53da6d1258f2abd902930b6af1134d1c">OPENCHANGE_CHECK_NOTIFICATION</a>, and <a class="el" href="mapicode_8h.html#a72f77c7e5d097e7b47c57c0405070d0c">OPENCHANGE_RETVAL_IF</a>.</p>

</div>
</div>
<a class="anchor" id="aa121bcd38e1bf43350ecab96c8b46e84"></a><!-- doxytag: member="IMAPIFolder.c::CreateMessage" ref="aa121bcd38e1bf43350ecab96c8b46e84" args="(mapi_object_t *obj_folder, mapi_object_t *obj_message)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">_PUBLIC_ enum MAPISTATUS CreateMessage </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structmapi__object.html">mapi_object_t</a> *&nbsp;</td>
          <td class="paramname"> <em>obj_folder</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="structmapi__object.html">mapi_object_t</a> *&nbsp;</td>
          <td class="paramname"> <em>obj_message</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">
<p>The function creates a message in the specified folder, and returns a pointer on this message.</p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>obj_folder</em>&nbsp;</td><td>the folder to create the message in. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>obj_message</em>&nbsp;</td><td>pointer to the newly created message.</td></tr>
  </table>
  </dd>
</dl>
<dl class="return"><dt><b>Returns:</b></dt><dd>MAPI_E_SUCCESS on success, otherwise MAPI error.</dd></dl>
<dl class="note"><dt><b>Note:</b></dt><dd>Developers may also call <a class="el" href="IUnknown_8c.html#a8237c7fc76377cb07f3f55920d6f20de">GetLastError()</a> to retrieve the last MAPI error code. Possible MAPI error codes are:<ul>
<li>MAPI_E_NOT_INITIALIZED: MAPI subsystem has not been initialized</li>
<li>MAPI_E_CALL_FAILED: A network problem was encountered during the transaction</li>
</ul>
</dd></dl>
<dl class="see"><dt><b>See also:</b></dt><dd><a class="el" href="proto_8h.html#a5d20a82a73d463254ac5e688f0f0cb0f">OpenFolder</a>, <a class="el" href="proto_8h.html#abd450cbfa8897602cbc1cc7e0fa56ce5">DeleteMessage</a>, <a class="el" href="proto_8h.html#a8237c7fc76377cb07f3f55920d6f20de">GetLastError</a> </dd></dl>

<p>References <a class="el" href="structmapi__provider.html#aa2906ad67334b042836f003e766d6d64">mapi_provider::ctx</a>, <a class="el" href="structmapi__session.html#a0d032340047573649b7527e660cac594">mapi_session::emsmdb</a>, <a class="el" href="emsmdb_8c.html#ae07f13624739ffff34e89ed3003a354e">emsmdb_transaction()</a>, <a class="el" href="cdo__mapi_8c.html#aa3c2b68912988f290961037c76478495">global_mapi_ctx</a>, <a class="el" href="mapi__object_8c.html#aa94645f34e6c4bf1c0631dffb0742676">mapi_object_get_handle()</a>, <a class="el" href="mapi__object_8c.html#ad4477e1e7c6dd8314638a9886b570209">mapi_object_get_id()</a>, <a class="el" href="mapi__object_8c.html#a96bfa7545b6e9ad350c42ba0abd07da8">mapi_object_get_logon_id()</a>, <a class="el" href="mapi__object_8c.html#ae5ef3137838fbc0c3eaedd7da99f8adc">mapi_object_get_session()</a>, <a class="el" href="mapi__object_8c.html#a6cad283dc5a1228734e816adb30aa53c">mapi_object_set_handle()</a>, <a class="el" href="mapi__object_8c.html#a845af67422945480121797b8a44ab14d">mapi_object_set_logon_id()</a>, <a class="el" href="mapi__object_8c.html#a373e9bd46155ea22e816fa66944f22a6">mapi_object_set_session()</a>, <a class="el" href="mapicode_8h.html#a53da6d1258f2abd902930b6af1134d1c">OPENCHANGE_CHECK_NOTIFICATION</a>, and <a class="el" href="mapicode_8h.html#a72f77c7e5d097e7b47c57c0405070d0c">OPENCHANGE_RETVAL_IF</a>.</p>

</div>
</div>
<a class="anchor" id="a616318752860658e5f5f376811cfd337"></a><!-- doxytag: member="IMAPIFolder.c::DeleteFolder" ref="a616318752860658e5f5f376811cfd337" args="(mapi_object_t *obj_parent, mapi_id_t FolderId, uint8_t DeleteFolderFlags, bool *PartialCompletion)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">_PUBLIC_ enum MAPISTATUS DeleteFolder </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structmapi__object.html">mapi_object_t</a> *&nbsp;</td>
          <td class="paramname"> <em>obj_parent</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="mapi__object_8h.html#ac1033858b28ee56b5f4d1578c297b87e">mapi_id_t</a>&nbsp;</td>
          <td class="paramname"> <em>FolderId</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint8_t&nbsp;</td>
          <td class="paramname"> <em>DeleteFolderFlags</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">bool *&nbsp;</td>
          <td class="paramname"> <em>PartialCompletion</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">
<p>Delete a folder</p>
<p>The function deletes a specified folder.</p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>obj_parent</em>&nbsp;</td><td>the folder containing the folder to be deleted </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>FolderId</em>&nbsp;</td><td>the ID of the folder to delete </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>DeleteFolderFlags</em>&nbsp;</td><td>control DeleteFolder operation behavior </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>PartialCompletion</em>&nbsp;</td><td>pointer on a boolean value which specify whether the operation was partially completed or not</td></tr>
  </table>
  </dd>
</dl>
<p>Possible values for DeleteFolderFlags are:</p>
<ol type="1">
<li>DEL_MESSAGES Delete all the messages in the folder</li>
<li>DEL_FOLDERS Delete the subfolder and all of its subfolders</li>
<li>DELETE_HARD_DELETE Hard delete the folder</li>
</ol>
<dl class="return"><dt><b>Returns:</b></dt><dd>MAPI_E_SUCCESS on success, otherwise MAPI error.</dd></dl>
<dl class="note"><dt><b>Note:</b></dt><dd>Developers may also call <a class="el" href="IUnknown_8c.html#a8237c7fc76377cb07f3f55920d6f20de">GetLastError()</a> to retrieve the last MAPI error code. Possible MAPI error codes are:<ul>
<li>MAPI_E_NOT_INITIALIZED: MAPI subsystem has not been initialized</li>
<li>MAPI_E_CALL_FAILED: A network problem was encountered during the transaction</li>
</ul>
</dd></dl>
<dl class="see"><dt><b>See also:</b></dt><dd><a class="el" href="proto_8h.html#a5d20a82a73d463254ac5e688f0f0cb0f">OpenFolder</a>, <a class="el" href="proto_8h.html#aa0d3c0451ce5f8584cce650ca3223b04">CreateFolder</a>, <a class="el" href="proto_8h.html#a364dcbce3198d58aa0ab6a813411bcbf">EmptyFolder</a>, <a class="el" href="proto_8h.html#a8237c7fc76377cb07f3f55920d6f20de">GetLastError</a> </dd></dl>

<p>References <a class="el" href="structmapi__provider.html#aa2906ad67334b042836f003e766d6d64">mapi_provider::ctx</a>, <a class="el" href="structmapi__session.html#a0d032340047573649b7527e660cac594">mapi_session::emsmdb</a>, <a class="el" href="emsmdb_8c.html#ae07f13624739ffff34e89ed3003a354e">emsmdb_transaction()</a>, <a class="el" href="cdo__mapi_8c.html#aa3c2b68912988f290961037c76478495">global_mapi_ctx</a>, <a class="el" href="mapi__object_8c.html#aa94645f34e6c4bf1c0631dffb0742676">mapi_object_get_handle()</a>, <a class="el" href="mapi__object_8c.html#a96bfa7545b6e9ad350c42ba0abd07da8">mapi_object_get_logon_id()</a>, <a class="el" href="mapi__object_8c.html#ae5ef3137838fbc0c3eaedd7da99f8adc">mapi_object_get_session()</a>, <a class="el" href="mapicode_8h.html#a53da6d1258f2abd902930b6af1134d1c">OPENCHANGE_CHECK_NOTIFICATION</a>, and <a class="el" href="mapicode_8h.html#a72f77c7e5d097e7b47c57c0405070d0c">OPENCHANGE_RETVAL_IF</a>.</p>

</div>
</div>
<a class="anchor" id="a570002287fc409bfb451f4e35481c6a0"></a><!-- doxytag: member="IMAPIFolder.c::DeleteMessage" ref="a570002287fc409bfb451f4e35481c6a0" args="(mapi_object_t *obj_folder, mapi_id_t *id_messages, uint32_t cn_messages)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">_PUBLIC_ enum MAPISTATUS DeleteMessage </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structmapi__object.html">mapi_object_t</a> *&nbsp;</td>
          <td class="paramname"> <em>obj_folder</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="mapi__object_8h.html#ac1033858b28ee56b5f4d1578c297b87e">mapi_id_t</a> *&nbsp;</td>
          <td class="paramname"> <em>id_messages</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t&nbsp;</td>
          <td class="paramname"> <em>cn_messages</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">
<p>Delete one or more messages</p>
<p>This function deletes one or more messages based on their ids from a specified folder.</p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>obj_folder</em>&nbsp;</td><td>the folder to delete messages from </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>id_messages</em>&nbsp;</td><td>the list of ids </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>cn_messages</em>&nbsp;</td><td>the number of messages in the id list.</td></tr>
  </table>
  </dd>
</dl>
<dl class="return"><dt><b>Returns:</b></dt><dd>MAPI_E_SUCCESS on success, otherwise MAPI error.</dd></dl>
<dl class="note"><dt><b>Note:</b></dt><dd>Developers may also call <a class="el" href="IUnknown_8c.html#a8237c7fc76377cb07f3f55920d6f20de">GetLastError()</a> to retrieve the last MAPI error code. Possible MAPI error codes are:<ul>
<li>MAPI_E_NOT_INITIALIZED: MAPI subsystem has not been initialized</li>
<li>MAPI_E_CALL_FAILED: A network problem was encountered during the transaction</li>
</ul>
</dd></dl>
<dl class="see"><dt><b>See also:</b></dt><dd><a class="el" href="proto_8h.html#a5d20a82a73d463254ac5e688f0f0cb0f">OpenFolder</a>, <a class="el" href="proto_8h.html#acd2d9aaa13e6138886bacdcea51695d3">CreateMessage</a>, <a class="el" href="proto_8h.html#a8237c7fc76377cb07f3f55920d6f20de">GetLastError</a> </dd></dl>

<p>References <a class="el" href="structmapi__provider.html#aa2906ad67334b042836f003e766d6d64">mapi_provider::ctx</a>, <a class="el" href="structmapi__session.html#a0d032340047573649b7527e660cac594">mapi_session::emsmdb</a>, <a class="el" href="emsmdb_8c.html#ae07f13624739ffff34e89ed3003a354e">emsmdb_transaction()</a>, <a class="el" href="cdo__mapi_8c.html#aa3c2b68912988f290961037c76478495">global_mapi_ctx</a>, <a class="el" href="mapi__object_8c.html#aa94645f34e6c4bf1c0631dffb0742676">mapi_object_get_handle()</a>, <a class="el" href="mapi__object_8c.html#a96bfa7545b6e9ad350c42ba0abd07da8">mapi_object_get_logon_id()</a>, <a class="el" href="mapi__object_8c.html#ae5ef3137838fbc0c3eaedd7da99f8adc">mapi_object_get_session()</a>, <a class="el" href="mapicode_8h.html#a53da6d1258f2abd902930b6af1134d1c">OPENCHANGE_CHECK_NOTIFICATION</a>, and <a class="el" href="mapicode_8h.html#a72f77c7e5d097e7b47c57c0405070d0c">OPENCHANGE_RETVAL_IF</a>.</p>

</div>
</div>
<a class="anchor" id="aa9fd00c745b4d7bb4ca4bc091a58caac"></a><!-- doxytag: member="IMAPIFolder.c::EmptyFolder" ref="aa9fd00c745b4d7bb4ca4bc091a58caac" args="(mapi_object_t *obj_folder)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">_PUBLIC_ enum MAPISTATUS EmptyFolder </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structmapi__object.html">mapi_object_t</a> *&nbsp;</td>
          <td class="paramname"> <em>obj_folder</em></td>
          <td>&nbsp;)&nbsp;</td>
          <td></td>
        </tr>
      </table>
</div>
<div class="memdoc">
<p>Empty the contents of a folder</p>
<p>This function empties (clears) the contents of a specified folder.</p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>obj_folder</em>&nbsp;</td><td>the folder to empty</td></tr>
  </table>
  </dd>
</dl>
<dl class="return"><dt><b>Returns:</b></dt><dd>MAPI_E_SUCCESS on success, otherwise MAPI error.</dd></dl>
<dl class="note"><dt><b>Note:</b></dt><dd>Developers may also call <a class="el" href="IUnknown_8c.html#a8237c7fc76377cb07f3f55920d6f20de">GetLastError()</a> to retrieve the last MAPI error code. Possible MAPI error codes are:<ul>
<li>MAPI_E_NOT_INITIALIZED: MAPI subsystem has not been initialized</li>
<li>MAPI_E_CALL_FAILED: A network problem was encountered during the transaction</li>
</ul>
</dd></dl>
<dl class="see"><dt><b>See also:</b></dt><dd><a class="el" href="proto_8h.html#a5d20a82a73d463254ac5e688f0f0cb0f">OpenFolder</a>, <a class="el" href="proto_8h.html#aa0d3c0451ce5f8584cce650ca3223b04">CreateFolder</a>, <a class="el" href="proto_8h.html#a89202179905d03cb95b31b430790b9a1">DeleteFolder</a>, <a class="el" href="proto_8h.html#a8237c7fc76377cb07f3f55920d6f20de">GetLastError</a> </dd></dl>

<p>References <a class="el" href="structmapi__provider.html#aa2906ad67334b042836f003e766d6d64">mapi_provider::ctx</a>, <a class="el" href="structmapi__session.html#a0d032340047573649b7527e660cac594">mapi_session::emsmdb</a>, <a class="el" href="emsmdb_8c.html#ae07f13624739ffff34e89ed3003a354e">emsmdb_transaction()</a>, <a class="el" href="cdo__mapi_8c.html#aa3c2b68912988f290961037c76478495">global_mapi_ctx</a>, <a class="el" href="mapi__object_8c.html#aa94645f34e6c4bf1c0631dffb0742676">mapi_object_get_handle()</a>, <a class="el" href="mapi__object_8c.html#a96bfa7545b6e9ad350c42ba0abd07da8">mapi_object_get_logon_id()</a>, <a class="el" href="mapi__object_8c.html#ae5ef3137838fbc0c3eaedd7da99f8adc">mapi_object_get_session()</a>, <a class="el" href="mapicode_8h.html#a53da6d1258f2abd902930b6af1134d1c">OPENCHANGE_CHECK_NOTIFICATION</a>, and <a class="el" href="mapicode_8h.html#a72f77c7e5d097e7b47c57c0405070d0c">OPENCHANGE_RETVAL_IF</a>.</p>

</div>
</div>
<a class="anchor" id="a505af78b45a3299cea6c3c60eff4bb79"></a><!-- doxytag: member="IMAPIFolder.c::GetMessageStatus" ref="a505af78b45a3299cea6c3c60eff4bb79" args="(mapi_object_t *obj_folder, mapi_id_t msgid, uint32_t *ulStatus)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">_PUBLIC_ enum MAPISTATUS GetMessageStatus </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structmapi__object.html">mapi_object_t</a> *&nbsp;</td>
          <td class="paramname"> <em>obj_folder</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="mapi__object_8h.html#ac1033858b28ee56b5f4d1578c297b87e">mapi_id_t</a>&nbsp;</td>
          <td class="paramname"> <em>msgid</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t *&nbsp;</td>
          <td class="paramname"> <em>ulStatus</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">
<p>Obtain the status associated with a message</p>
<p>This function obtains the status associated with a message in the given folder.</p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>obj_folder</em>&nbsp;</td><td>the folder where the message is located </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>msgid</em>&nbsp;</td><td>the message ID </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>ulStatus</em>&nbsp;</td><td>the message status</td></tr>
  </table>
  </dd>
</dl>
<dl class="return"><dt><b>Returns:</b></dt><dd>MAPI_E_SUCCESS on success, otherwise MAPI error.</dd></dl>
<dl class="note"><dt><b>Note:</b></dt><dd>Developers may also call <a class="el" href="IUnknown_8c.html#a8237c7fc76377cb07f3f55920d6f20de">GetLastError()</a> to retrieve the last MAPI error code. Possible MAPI error codes are:<ul>
<li>MAPI_E_NOT_INITIALIZED: MAPI subsystem has not been initialized</li>
<li>MAPI_E_CALL_FAILED: A network problem was encountered during the transaction </li>
</ul>
</dd></dl>

<p>References <a class="el" href="structmapi__provider.html#aa2906ad67334b042836f003e766d6d64">mapi_provider::ctx</a>, <a class="el" href="structmapi__session.html#a0d032340047573649b7527e660cac594">mapi_session::emsmdb</a>, <a class="el" href="emsmdb_8c.html#ae07f13624739ffff34e89ed3003a354e">emsmdb_transaction()</a>, <a class="el" href="cdo__mapi_8c.html#aa3c2b68912988f290961037c76478495">global_mapi_ctx</a>, <a class="el" href="mapi__object_8c.html#aa94645f34e6c4bf1c0631dffb0742676">mapi_object_get_handle()</a>, <a class="el" href="mapi__object_8c.html#a96bfa7545b6e9ad350c42ba0abd07da8">mapi_object_get_logon_id()</a>, <a class="el" href="mapi__object_8c.html#ae5ef3137838fbc0c3eaedd7da99f8adc">mapi_object_get_session()</a>, <a class="el" href="mapicode_8h.html#a53da6d1258f2abd902930b6af1134d1c">OPENCHANGE_CHECK_NOTIFICATION</a>, and <a class="el" href="mapicode_8h.html#a72f77c7e5d097e7b47c57c0405070d0c">OPENCHANGE_RETVAL_IF</a>.</p>

</div>
</div>
<a class="anchor" id="a01717e01f01cc28fdbfa503952af66e5"></a><!-- doxytag: member="IMAPIFolder.c::HardDeleteMessage" ref="a01717e01f01cc28fdbfa503952af66e5" args="(mapi_object_t *obj_folder, mapi_id_t *id_messages, uint16_t cn_messages)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">_PUBLIC_ enum MAPISTATUS HardDeleteMessage </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structmapi__object.html">mapi_object_t</a> *&nbsp;</td>
          <td class="paramname"> <em>obj_folder</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="mapi__object_8h.html#ac1033858b28ee56b5f4d1578c297b87e">mapi_id_t</a> *&nbsp;</td>
          <td class="paramname"> <em>id_messages</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint16_t&nbsp;</td>
          <td class="paramname"> <em>cn_messages</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">
<p>Hard delete one or more messages</p>
<p>This function hard deletes one or more messages based on their ids from a specified folder.</p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>obj_folder</em>&nbsp;</td><td>the folder to hard delete messages from </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>id_messages</em>&nbsp;</td><td>the list of ids </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>cn_messages</em>&nbsp;</td><td>the number of messages in the id list.</td></tr>
  </table>
  </dd>
</dl>
<dl class="return"><dt><b>Returns:</b></dt><dd>MAPI_E_SUCCESS on success, otherwise MAPI error.</dd></dl>
<dl class="note"><dt><b>Note:</b></dt><dd>Developers may also call <a class="el" href="IUnknown_8c.html#a8237c7fc76377cb07f3f55920d6f20de">GetLastError()</a> to retrieve the last MAPI error code. Possible MAPI error codes are:<ul>
<li>MAPI_E_NOT_INITIALIZED: MAPI subsystem has not been initialized</li>
<li>MAPI_E_INVALID_PARAMETER: the parent folder was not valid</li>
<li>MAPI_E_CALL_FAILED: A network problem was encountered during the transaction</li>
</ul>
</dd></dl>
<dl class="see"><dt><b>See also:</b></dt><dd><a class="el" href="proto_8h.html#a5d20a82a73d463254ac5e688f0f0cb0f">OpenFolder</a>, <a class="el" href="proto_8h.html#acd2d9aaa13e6138886bacdcea51695d3">CreateMessage</a>, <a class="el" href="proto_8h.html#a8237c7fc76377cb07f3f55920d6f20de">GetLastError</a> </dd></dl>

<p>References <a class="el" href="structmapi__provider.html#aa2906ad67334b042836f003e766d6d64">mapi_provider::ctx</a>, <a class="el" href="structmapi__session.html#a0d032340047573649b7527e660cac594">mapi_session::emsmdb</a>, <a class="el" href="emsmdb_8c.html#ae07f13624739ffff34e89ed3003a354e">emsmdb_transaction()</a>, <a class="el" href="cdo__mapi_8c.html#aa3c2b68912988f290961037c76478495">global_mapi_ctx</a>, <a class="el" href="mapi__object_8c.html#aa94645f34e6c4bf1c0631dffb0742676">mapi_object_get_handle()</a>, <a class="el" href="mapi__object_8c.html#a96bfa7545b6e9ad350c42ba0abd07da8">mapi_object_get_logon_id()</a>, <a class="el" href="mapi__object_8c.html#ae5ef3137838fbc0c3eaedd7da99f8adc">mapi_object_get_session()</a>, and <a class="el" href="mapicode_8h.html#a72f77c7e5d097e7b47c57c0405070d0c">OPENCHANGE_RETVAL_IF</a>.</p>

</div>
</div>
<a class="anchor" id="a2ae847258164d47c97d85be0263310e3"></a><!-- doxytag: member="IMAPIFolder.c::HardDeleteMessagesAndSubfolders" ref="a2ae847258164d47c97d85be0263310e3" args="(mapi_object_t *obj_folder)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">_PUBLIC_ enum MAPISTATUS HardDeleteMessagesAndSubfolders </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structmapi__object.html">mapi_object_t</a> *&nbsp;</td>
          <td class="paramname"> <em>obj_folder</em></td>
          <td>&nbsp;)&nbsp;</td>
          <td></td>
        </tr>
      </table>
</div>
<div class="memdoc">
<p>Hard delete the contents of a folder, including subfolders</p>
<p>This function empties (clears) the contents of a specified folder.</p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>obj_folder</em>&nbsp;</td><td>the folder to empty</td></tr>
  </table>
  </dd>
</dl>
<dl class="return"><dt><b>Returns:</b></dt><dd>MAPI_E_SUCCESS on success, otherwise MAPI error.</dd></dl>
<dl class="note"><dt><b>Note:</b></dt><dd>Developers may also call <a class="el" href="IUnknown_8c.html#a8237c7fc76377cb07f3f55920d6f20de">GetLastError()</a> to retrieve the last MAPI error code. Possible MAPI error codes are:<ul>
<li>MAPI_E_NOT_INITIALIZED: MAPI subsystem has not been initialized</li>
<li>MAPI_E_INVALID_PARAMETER: obj_folder is not valid</li>
<li>MAPI_E_CALL_FAILED: A network problem was encountered during the transaction</li>
</ul>
</dd></dl>
<dl class="see"><dt><b>See also:</b></dt><dd><a class="el" href="proto_8h.html#a89202179905d03cb95b31b430790b9a1">DeleteFolder</a>, <a class="el" href="proto_8h.html#a364dcbce3198d58aa0ab6a813411bcbf">EmptyFolder</a> </dd></dl>

<p>References <a class="el" href="structmapi__provider.html#aa2906ad67334b042836f003e766d6d64">mapi_provider::ctx</a>, <a class="el" href="structmapi__session.html#a0d032340047573649b7527e660cac594">mapi_session::emsmdb</a>, <a class="el" href="emsmdb_8c.html#ae07f13624739ffff34e89ed3003a354e">emsmdb_transaction()</a>, <a class="el" href="cdo__mapi_8c.html#aa3c2b68912988f290961037c76478495">global_mapi_ctx</a>, <a class="el" href="mapi__object_8c.html#aa94645f34e6c4bf1c0631dffb0742676">mapi_object_get_handle()</a>, <a class="el" href="mapi__object_8c.html#a96bfa7545b6e9ad350c42ba0abd07da8">mapi_object_get_logon_id()</a>, <a class="el" href="mapi__object_8c.html#ae5ef3137838fbc0c3eaedd7da99f8adc">mapi_object_get_session()</a>, and <a class="el" href="mapicode_8h.html#a72f77c7e5d097e7b47c57c0405070d0c">OPENCHANGE_RETVAL_IF</a>.</p>

</div>
</div>
<a class="anchor" id="a3b7f73870664d7fe2f94c29e35e3e2f2"></a><!-- doxytag: member="IMAPIFolder.c::MoveCopyMessages" ref="a3b7f73870664d7fe2f94c29e35e3e2f2" args="(mapi_object_t *obj_src, mapi_object_t *obj_dst, mapi_id_array_t *message_id, bool WantCopy)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">_PUBLIC_ enum MAPISTATUS MoveCopyMessages </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structmapi__object.html">mapi_object_t</a> *&nbsp;</td>
          <td class="paramname"> <em>obj_src</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="structmapi__object.html">mapi_object_t</a> *&nbsp;</td>
          <td class="paramname"> <em>obj_dst</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="structmapi__id__array.html">mapi_id_array_t</a> *&nbsp;</td>
          <td class="paramname"> <em>message_id</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">bool&nbsp;</td>
          <td class="paramname"> <em>WantCopy</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">
<p>Copy or Move a message from a folder to another</p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>obj_src</em>&nbsp;</td><td>The source folder </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>obj_dst</em>&nbsp;</td><td>The destination folder </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>message_id</em>&nbsp;</td><td>pointer to container object for message ids. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>WantCopy</em>&nbsp;</td><td>boolean value, defines whether the operation is a copy or a move</td></tr>
  </table>
  </dd>
</dl>
<p>Possible values for WantCopy:</p>
<ol type="1">
<li>0: Move</li>
<li>1: Copy</li>
</ol>
<dl class="return"><dt><b>Returns:</b></dt><dd>MAPI_E_SUCCESS on success, otherwise MAPI error.</dd></dl>
<dl class="note"><dt><b>Note:</b></dt><dd>Developers may also call <a class="el" href="IUnknown_8c.html#a8237c7fc76377cb07f3f55920d6f20de">GetLastError()</a> to retrieve the last MAPI error code. Possible MAPI error codes are:<ul>
<li>MAPI_E_NOT_INITIALIZED: MAPI subsystem has not been initialized</li>
<li>MAPI_E_CALL_FAILED: A network problem was encountered during the transaction</li>
</ul>
</dd></dl>
<dl class="see"><dt><b>See also:</b></dt><dd><a class="el" href="proto_8h.html#a5d20a82a73d463254ac5e688f0f0cb0f">OpenFolder</a>, <a class="el" href="proto_8h.html#a8237c7fc76377cb07f3f55920d6f20de">GetLastError</a> </dd></dl>

<p>References <a class="el" href="structmapi__id__array.html#a2d3dad88056dae791e6e92c8d8ea0bc7">mapi_id_array::count</a>, <a class="el" href="structmapi__provider.html#aa2906ad67334b042836f003e766d6d64">mapi_provider::ctx</a>, <a class="el" href="structmapi__session.html#a0d032340047573649b7527e660cac594">mapi_session::emsmdb</a>, <a class="el" href="emsmdb_8c.html#ae07f13624739ffff34e89ed3003a354e">emsmdb_transaction()</a>, <a class="el" href="cdo__mapi_8c.html#aa3c2b68912988f290961037c76478495">global_mapi_ctx</a>, <a class="el" href="mapi__id__array_8c.html#a5cc08c5509c61008c51d7214d2a4ee58">mapi_id_array_get()</a>, <a class="el" href="mapi__object_8c.html#aa94645f34e6c4bf1c0631dffb0742676">mapi_object_get_handle()</a>, <a class="el" href="mapi__object_8c.html#a96bfa7545b6e9ad350c42ba0abd07da8">mapi_object_get_logon_id()</a>, <a class="el" href="mapi__object_8c.html#ae5ef3137838fbc0c3eaedd7da99f8adc">mapi_object_get_session()</a>, <a class="el" href="mapicode_8h.html#a53da6d1258f2abd902930b6af1134d1c">OPENCHANGE_CHECK_NOTIFICATION</a>, and <a class="el" href="mapicode_8h.html#a72f77c7e5d097e7b47c57c0405070d0c">OPENCHANGE_RETVAL_IF</a>.</p>

</div>
</div>
<a class="anchor" id="a81405ca3fef5b65fae9d1cb33d315e08"></a><!-- doxytag: member="IMAPIFolder.c::MoveFolder" ref="a81405ca3fef5b65fae9d1cb33d315e08" args="(mapi_object_t *obj_folder, mapi_object_t *obj_src, mapi_object_t *obj_dst, char *NewFolderName, bool UseUnicode)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">_PUBLIC_ enum MAPISTATUS MoveFolder </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structmapi__object.html">mapi_object_t</a> *&nbsp;</td>
          <td class="paramname"> <em>obj_folder</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="structmapi__object.html">mapi_object_t</a> *&nbsp;</td>
          <td class="paramname"> <em>obj_src</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="structmapi__object.html">mapi_object_t</a> *&nbsp;</td>
          <td class="paramname"> <em>obj_dst</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">char *&nbsp;</td>
          <td class="paramname"> <em>NewFolderName</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">bool&nbsp;</td>
          <td class="paramname"> <em>UseUnicode</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">
<p>Moves a folder</p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>obj_folder</em>&nbsp;</td><td>the folder to move </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>obj_src</em>&nbsp;</td><td>source object where the folder to move is stored </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>obj_dst</em>&nbsp;</td><td>destination object where the folder will be moved </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>NewFolderName</em>&nbsp;</td><td>the new folder name in the destination folder </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>UseUnicode</em>&nbsp;</td><td>whether the folder name is unicode encoded or not</td></tr>
  </table>
  </dd>
</dl>
<dl class="return"><dt><b>Returns:</b></dt><dd>MAPI_E_SUCCESS on success, otherwise MAPI error.</dd></dl>
<dl class="note"><dt><b>Note:</b></dt><dd>Developers may also call <a class="el" href="IUnknown_8c.html#a8237c7fc76377cb07f3f55920d6f20de">GetLastError()</a> to retrieve the last MAPI error code. Possible MAPI error codes are:<ul>
<li>MAPI_E_NOT_INITIALIZED: MAPI subsystem has not been initialized</li>
<li>MAPI_E_CALL_FAILED: A network problem was encountered during the transaction</li>
</ul>
</dd></dl>
<dl class="see"><dt><b>See also:</b></dt><dd><a class="el" href="proto_8h.html#a5d20a82a73d463254ac5e688f0f0cb0f">OpenFolder</a>, <a class="el" href="proto_8h.html#a4716ce81dca05da5c568db239f95acfe">CopyFolder</a> </dd></dl>

<p>References <a class="el" href="structmapi__provider.html#aa2906ad67334b042836f003e766d6d64">mapi_provider::ctx</a>, <a class="el" href="structmapi__session.html#a0d032340047573649b7527e660cac594">mapi_session::emsmdb</a>, <a class="el" href="emsmdb_8c.html#ae07f13624739ffff34e89ed3003a354e">emsmdb_transaction()</a>, <a class="el" href="cdo__mapi_8c.html#aa3c2b68912988f290961037c76478495">global_mapi_ctx</a>, <a class="el" href="mapi__object_8c.html#aa94645f34e6c4bf1c0631dffb0742676">mapi_object_get_handle()</a>, <a class="el" href="mapi__object_8c.html#ad4477e1e7c6dd8314638a9886b570209">mapi_object_get_id()</a>, <a class="el" href="mapi__object_8c.html#a96bfa7545b6e9ad350c42ba0abd07da8">mapi_object_get_logon_id()</a>, <a class="el" href="mapi__object_8c.html#ae5ef3137838fbc0c3eaedd7da99f8adc">mapi_object_get_session()</a>, <a class="el" href="mapicode_8h.html#a53da6d1258f2abd902930b6af1134d1c">OPENCHANGE_CHECK_NOTIFICATION</a>, and <a class="el" href="mapicode_8h.html#a72f77c7e5d097e7b47c57c0405070d0c">OPENCHANGE_RETVAL_IF</a>.</p>

</div>
</div>
<a class="anchor" id="aa5c12f00fbd741c749ebe8c9c615fbd9"></a><!-- doxytag: member="IMAPIFolder.c::SetMessageStatus" ref="aa5c12f00fbd741c749ebe8c9c615fbd9" args="(mapi_object_t *obj_folder, mapi_id_t msgid, uint32_t ulNewStatus, uint32_t ulNewStatusMask, uint32_t *ulOldStatus)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">_PUBLIC_ enum MAPISTATUS SetMessageStatus </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structmapi__object.html">mapi_object_t</a> *&nbsp;</td>
          <td class="paramname"> <em>obj_folder</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="mapi__object_8h.html#ac1033858b28ee56b5f4d1578c297b87e">mapi_id_t</a>&nbsp;</td>
          <td class="paramname"> <em>msgid</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t&nbsp;</td>
          <td class="paramname"> <em>ulNewStatus</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t&nbsp;</td>
          <td class="paramname"> <em>ulNewStatusMask</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t *&nbsp;</td>
          <td class="paramname"> <em>ulOldStatus</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">
<p>Set the status associated with a message</p>
<p>This function sets the status associated with a message in the given folder.</p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>obj_folder</em>&nbsp;</td><td>the folder where the message is located </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>msgid</em>&nbsp;</td><td>the message ID </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>ulNewStatus</em>&nbsp;</td><td>the new status to be assigned </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>ulNewStatusMask</em>&nbsp;</td><td>bitmask of flags hat is applied to the new status indicating the flags to be set </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>ulOldStatus</em>&nbsp;</td><td>pointer on the previous status of the message</td></tr>
  </table>
  </dd>
</dl>
<p>ulNewStatusMask possible values:</p>
<ul>
<li>MSGSTATUS_DELMARKED: the message is marked for deletion</li>
<li>MSGSTATUS_HIDDEN: the message is not to be displayed</li>
<li>MSGSTATUS_HIGHLIGHTED: the message is to be displayed highlighted</li>
<li>MSGSTATUS_REMOTE_DELETE: the message has been marked for deletion on the remote message store without downloading to the local client.</li>
<li>MSGSTATUS_REMOTE_DOWNLOAD: the message has been marked for downloading from the remote message store to the local client.</li>
<li>MSGSTATUS_TAGGED: The message has been tagged for a client-defined purpose.</li>
</ul>
<dl class="return"><dt><b>Returns:</b></dt><dd>MAPI_E_SUCCESS on success, otherwise MAPI error.</dd></dl>
<dl class="note"><dt><b>Note:</b></dt><dd>Developers may also call <a class="el" href="IUnknown_8c.html#a8237c7fc76377cb07f3f55920d6f20de">GetLastError()</a> to retrieve the last MAPI error code. Possible MAPI error codes are:<ul>
<li>MAPI_E_NOT_INITIALIZED: MAPI subsystem has not been initialized</li>
<li>MAPI_E_CALL_FAILED: A network problem was encountered during the transaction </li>
</ul>
</dd></dl>

<p>References <a class="el" href="structmapi__provider.html#aa2906ad67334b042836f003e766d6d64">mapi_provider::ctx</a>, <a class="el" href="structmapi__session.html#a0d032340047573649b7527e660cac594">mapi_session::emsmdb</a>, <a class="el" href="emsmdb_8c.html#ae07f13624739ffff34e89ed3003a354e">emsmdb_transaction()</a>, <a class="el" href="cdo__mapi_8c.html#aa3c2b68912988f290961037c76478495">global_mapi_ctx</a>, <a class="el" href="mapi__object_8c.html#aa94645f34e6c4bf1c0631dffb0742676">mapi_object_get_handle()</a>, <a class="el" href="mapi__object_8c.html#a96bfa7545b6e9ad350c42ba0abd07da8">mapi_object_get_logon_id()</a>, <a class="el" href="mapi__object_8c.html#ae5ef3137838fbc0c3eaedd7da99f8adc">mapi_object_get_session()</a>, <a class="el" href="mapicode_8h.html#a53da6d1258f2abd902930b6af1134d1c">OPENCHANGE_CHECK_NOTIFICATION</a>, and <a class="el" href="mapicode_8h.html#a72f77c7e5d097e7b47c57c0405070d0c">OPENCHANGE_RETVAL_IF</a>.</p>

</div>
</div>
<a class="anchor" id="ada6550587b0ae4918a952ad8ac93704f"></a><!-- doxytag: member="IMAPIFolder.c::SetReadFlags" ref="ada6550587b0ae4918a952ad8ac93704f" args="(mapi_object_t *obj_folder, uint8_t ReadFlags, uint16_t MessageIdCount, uint64_t *MessageIds)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">_PUBLIC_ enum MAPISTATUS SetReadFlags </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structmapi__object.html">mapi_object_t</a> *&nbsp;</td>
          <td class="paramname"> <em>obj_folder</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint8_t&nbsp;</td>
          <td class="paramname"> <em>ReadFlags</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint16_t&nbsp;</td>
          <td class="paramname"> <em>MessageIdCount</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint64_t *&nbsp;</td>
          <td class="paramname"> <em>MessageIds</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">
<p>Set the Read Flags on one or more messages</p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>obj_folder</em>&nbsp;</td><td>the folder containing the messages to change </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>ReadFlags</em>&nbsp;</td><td>a bitmap of flags controlling the changes to PR_PROPERTY_FLAGS </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>MessageIdCount</em>&nbsp;</td><td>the number of messages in the MessageIds array </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>MessageIds</em>&nbsp;</td><td>an array of message ids to set Read flags for</td></tr>
  </table>
  </dd>
</dl>
<p>Note that the obj_folder argument is the object corresponding to the folder containing the messages (e.g. the result of <a class="el" href="IMAPIFolder_8c.html#a03a3f5d51af0ce6d0a92a5d319326f93">CreateFolder()</a> or <a class="el" href="IMsgStore_8c.html#a8b90a95da815aaed2c2728c2599007c1">OpenFolder()</a>. It is <em>not</em> the content table of that folder (unlike <a class="el" href="IMessage_8c.html#ad3d2a166b8e56d8fb8fa5e71e421a052">SetMessageReadFlag()</a>.)</p>
<dl class="return"><dt><b>Returns:</b></dt><dd>MAPI_E_SUCCESS on success, otherwise MAPI error.</dd></dl>
<dl class="note"><dt><b>Note:</b></dt><dd>Developers may also call <a class="el" href="IUnknown_8c.html#a8237c7fc76377cb07f3f55920d6f20de">GetLastError()</a> to retrieve the last MAPI error code. Possible MAPI error codes are:<ul>
<li>MAPI_E_NOT_INITIALIZED: MAPI subsystem has not been initialized</li>
<li>MAPI_E_CALL_FAILED: A network problem was encountered during the transaction</li>
</ul>
</dd></dl>
<dl class="see"><dt><b>See also:</b></dt><dd>SetMessageReadFlags for a slightly different version, working on a single message </dd></dl>

<p>References <a class="el" href="structmapi__provider.html#aa2906ad67334b042836f003e766d6d64">mapi_provider::ctx</a>, <a class="el" href="structmapi__session.html#a0d032340047573649b7527e660cac594">mapi_session::emsmdb</a>, <a class="el" href="emsmdb_8c.html#ae07f13624739ffff34e89ed3003a354e">emsmdb_transaction()</a>, <a class="el" href="cdo__mapi_8c.html#aa3c2b68912988f290961037c76478495">global_mapi_ctx</a>, <a class="el" href="mapi__object_8c.html#aa94645f34e6c4bf1c0631dffb0742676">mapi_object_get_handle()</a>, <a class="el" href="mapi__object_8c.html#a96bfa7545b6e9ad350c42ba0abd07da8">mapi_object_get_logon_id()</a>, <a class="el" href="mapi__object_8c.html#ae5ef3137838fbc0c3eaedd7da99f8adc">mapi_object_get_session()</a>, <a class="el" href="mapicode_8h.html#a53da6d1258f2abd902930b6af1134d1c">OPENCHANGE_CHECK_NOTIFICATION</a>, and <a class="el" href="mapicode_8h.html#a72f77c7e5d097e7b47c57c0405070d0c">OPENCHANGE_RETVAL_IF</a>.</p>

</div>
</div>
</div>
</div>
<br/>
<table style="clear:both; margin: 0.5em auto; width:80%; text-align: center; background-color:#f8f8f8; border:2px solid #e0e0e0; padding:5px;">
<tr>
<td> 
  <img alt="Creative Commons License" src="CC_SomeRightsReserved.png" width="90" height="30" border="0" /><br />
  <img alt="Creative Commons Attribution icon" src="24px-Cc-by_white.svg.png" width="24" height="24" border="0" />
  <img alt="Creative Commons Share Alike icon" src="24px-Cc-sa_white.svg.png" width="24" height="24" border="0" />
</td>
<td> <i><strong class="selflink">This content</strong> is licensed under the Creative Commons<br />
Attribution ShareAlike License v. 3.0:<br />
<a href="http://creativecommons.org/licenses/by-sa/3.0/" class="external free" title="http://creativecommons.org/licenses/by-sa/3.0/" rel="nofollow">http://creativecommons.org/licenses/by-sa/3.0/</a></i>
</td></tr></table>
<br/>
</div>
</div>
</body>
</html>