<html> <head> <title>MAPIClientLibraries 0.8 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.5.9 --> <div class="navigation" id="top"> <div class="tabs"> <ul> <li><a href="index.html"><span>Main Page</span></a></li> <li><a href="pages.html"><span>Related Pages</span></a></li> <li><a href="annotated.html"><span>Data 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="tabs"> <ul> <li><a href="files.html"><span>File List</span></a></li> <li><a href="globals.html"><span>Globals</span></a></li> </ul> </div> </div> <div class="contents"> <h1>libmapi/IABContainer.c File Reference</h1>Provides access to address book containers -- Used to perform name resolution. <a href="#_details">More...</a> <p> <code>#include <libmapi/libmapi.h></code><br> <table border="0" cellpadding="0" cellspacing="0"> <tr><td></td></tr> <tr><td colspan="2"><br><h2>Functions</h2></td></tr> <tr><td class="memItemLeft" nowrap align="right" valign="top">_PUBLIC_ enum MAPISTATUS </td><td class="memItemRight" valign="bottom"><a class="el" href="IABContainer_8c.html#d936e550d73780a978a726d9ce213562">GetABRecipientInfo</a> (struct mapi_session *session, const char *username, struct SPropTagArray *pPropTags, struct SRowSet **ppRowSet)</td></tr> <tr><td class="memItemLeft" nowrap align="right" valign="top">_PUBLIC_ enum MAPISTATUS </td><td class="memItemRight" valign="bottom"><a class="el" href="IABContainer_8c.html#73b59ff764022e1b5116a51c6f735c3d">GetGALTable</a> (struct mapi_session *session, struct SPropTagArray *SPropTagArray, struct SRowSet **SRowSet, uint32_t count, uint8_t ulFlags)</td></tr> <tr><td class="memItemLeft" nowrap align="right" valign="top">_PUBLIC_ enum MAPISTATUS </td><td class="memItemRight" valign="bottom"><a class="el" href="IABContainer_8c.html#983fbb1c5d57401c0141770b48f6e533">ResolveNames</a> (struct mapi_session *session, const char **usernames, struct SPropTagArray *props, struct SRowSet **rowset, struct SPropTagArray **flaglist, uint32_t flags)</td></tr> </table> <hr><h2>Detailed Description</h2> Provides access to address book containers -- Used to perform name resolution. <p> <hr><h2>Function Documentation</h2> <a class="anchor" name="d936e550d73780a978a726d9ce213562"></a><!-- doxytag: member="IABContainer.c::GetABRecipientInfo" ref="d936e550d73780a978a726d9ce213562" args="(struct mapi_session *session, const char *username, struct SPropTagArray *pPropTags, struct SRowSet **ppRowSet)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">_PUBLIC_ enum MAPISTATUS GetABRecipientInfo </td> <td>(</td> <td class="paramtype">struct mapi_session * </td> <td class="paramname"> <em>session</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype">const char * </td> <td class="paramname"> <em>username</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype">struct SPropTagArray * </td> <td class="paramname"> <em>pPropTags</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype">struct SRowSet ** </td> <td class="paramname"> <em>ppRowSet</em></td><td> </td> </tr> <tr> <td></td> <td>)</td> <td></td><td></td><td></td> </tr> </table> </div> <div class="memdoc"> <p> Retrieve Address Book information for a given recipient<p> <dl compact><dt><b>Parameters:</b></dt><dd> <table border="0" cellspacing="2" cellpadding="0"> <tr><td valign="top"></td><td valign="top"><em>session</em> </td><td>pointer to the MAPI session context </td></tr> <tr><td valign="top"></td><td valign="top"><em>username</em> </td><td>pointer to the username to retrieve information from </td></tr> <tr><td valign="top"></td><td valign="top"><em>pPropTags</em> </td><td>pointer to the property tags array to lookup </td></tr> <tr><td valign="top"></td><td valign="top"><em>ppRowSet</em> </td><td>pointer on pointer to the results</td></tr> </table> </dl> Note that if pPropTags is NULL, then GetABNameInfo will fetch the following default property tags:<ol type=1> <li>PR_ADDRTYPE_UNICODE</li><li>PR_EMAIL_ADDRESS_UNICODE</li><li>PR_DISPLAY_NAME_UNICODE</li><li>PR_OBJECT_TYPE</li></ol> <p> <dl class="return" compact><dt><b>Returns:</b></dt><dd>MAPI_E_SUCCESS on success, otherwise MAPI error.</dd></dl> <dl class="note" compact><dt><b>Note:</b></dt><dd>Developers may also call <a class="el" href="IUnknown_8c.html#8237c7fc76377cb07f3f55920d6f20de">GetLastError()</a> to retrieve the last MAPI error code. Possible MAPI error codes are:<ol type=1> <li>MAPI_E_NOT_INITIALIZED if MAPI subsystem is not initialized</li><li>MAPI_E_SESSION_LIMIT if the NSPI session is unavailable</li><li>MAPI_E_INVALID_PARAMETER if a function parameter is invalid</li><li>MAPI_E_NOT_FOUND if the username to lookup doesn't match any records</li></ol> </dd></dl> <dl class="see" compact><dt><b>See also:</b></dt><dd><a class="el" href="nspi_8c.html#9143233bb314dcd3a5701e4aaffae7ae">nspi_DNToMId</a>, <a class="el" href="nspi_8c.html#17da9e122399b4a78590a76e6d3bdc9a">nspi_GetProps</a> </dd></dl> <p>References <a class="el" href="IUnknown_8c_source.html#l00082">MAPIFreeBuffer()</a>, <a class="el" href="nspi_8c_source.html#l00515">nspi_DNToMId()</a>, <a class="el" href="nspi_8c_source.html#l00599">nspi_GetProps()</a>, and <a class="el" href="IABContainer_8c_source.html#l00063">ResolveNames()</a>.</p> <p>Referenced by <a class="el" href="freebusy_8c_source.html#l00057">GetUserFreeBusyData()</a>.</p> </div> </div><p> <a class="anchor" name="73b59ff764022e1b5116a51c6f735c3d"></a><!-- doxytag: member="IABContainer.c::GetGALTable" ref="73b59ff764022e1b5116a51c6f735c3d" args="(struct mapi_session *session, struct SPropTagArray *SPropTagArray, struct SRowSet **SRowSet, uint32_t count, uint8_t ulFlags)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">_PUBLIC_ enum MAPISTATUS GetGALTable </td> <td>(</td> <td class="paramtype">struct mapi_session * </td> <td class="paramname"> <em>session</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype">struct SPropTagArray * </td> <td class="paramname"> <em>SPropTagArray</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype">struct SRowSet ** </td> <td class="paramname"> <em>SRowSet</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype">uint32_t </td> <td class="paramname"> <em>count</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype">uint8_t </td> <td class="paramname"> <em>ulFlags</em></td><td> </td> </tr> <tr> <td></td> <td>)</td> <td></td><td></td><td></td> </tr> </table> </div> <div class="memdoc"> <p> Retrieve the global address list<p> <dl compact><dt><b>Parameters:</b></dt><dd> <table border="0" cellspacing="2" cellpadding="0"> <tr><td valign="top"></td><td valign="top"><em>session</em> </td><td>pointer to the MAPI session context </td></tr> <tr><td valign="top"></td><td valign="top"><em>SPropTagArray</em> </td><td>pointer on an array of MAPI properties we want to fetch </td></tr> <tr><td valign="top"></td><td valign="top"><em>SRowSet</em> </td><td>pointer on the rows returned </td></tr> <tr><td valign="top"></td><td valign="top"><em>count</em> </td><td>the number of rows we want to fetch </td></tr> <tr><td valign="top"></td><td valign="top"><em>ulFlags</em> </td><td>specify the table cursor location</td></tr> </table> </dl> Possible value for ulFlags:<ol type=1> <li>TABLE_START: Fetch rows from the beginning of the table</li><li>TABLE_CUR: Fetch rows from current table location</li></ol> <p> <dl class="return" compact><dt><b>Returns:</b></dt><dd>MAPI_E_SUCCESS on success, otherwise MAPI error.</dd></dl> <dl class="note" compact><dt><b>Note:</b></dt><dd>Developers may also call <a class="el" href="IUnknown_8c.html#8237c7fc76377cb07f3f55920d6f20de">GetLastError()</a> to retrieve the last MAPI error code. Possible MAPI error codes are:<ol type=1> <li>MAPI_E_NOT_INITIALIZED: MAPI subsystem has not been initialized</li><li>MAPI_E_SESSION_LIMIT: No session has been opened on the provider</li><li>MAPI_E_INVALID_PARAMETER: if a function parameter is invalid</li><li>MAPI_E_CALL_FAILED: A network problem was encountered during the transaction</li></ol> </dd></dl> <dl class="see" compact><dt><b>See also:</b></dt><dd><a class="el" href="cdo__mapi_8c.html#2a42a622654ad8f1020d152028efe67b">MapiLogonEx</a>, <a class="el" href="cdo__mapi_8c.html#898df5110aab8e75e97574dc52acc1fa">MapiLogonProvider</a> </dd></dl> <p>References <a class="el" href="nspi_8c_source.html#l00232">nspi_QueryRows()</a>.</p> </div> </div><p> <a class="anchor" name="983fbb1c5d57401c0141770b48f6e533"></a><!-- doxytag: member="IABContainer.c::ResolveNames" ref="983fbb1c5d57401c0141770b48f6e533" args="(struct mapi_session *session, const char **usernames, struct SPropTagArray *props, struct SRowSet **rowset, struct SPropTagArray **flaglist, uint32_t flags)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">_PUBLIC_ enum MAPISTATUS ResolveNames </td> <td>(</td> <td class="paramtype">struct mapi_session * </td> <td class="paramname"> <em>session</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype">const char ** </td> <td class="paramname"> <em>usernames</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype">struct SPropTagArray * </td> <td class="paramname"> <em>props</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype">struct SRowSet ** </td> <td class="paramname"> <em>rowset</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype">struct SPropTagArray ** </td> <td class="paramname"> <em>flaglist</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype">uint32_t </td> <td class="paramname"> <em>flags</em></td><td> </td> </tr> <tr> <td></td> <td>)</td> <td></td><td></td><td></td> </tr> </table> </div> <div class="memdoc"> <p> Resolve user names against the Windows Address Book Provider<p> <dl compact><dt><b>Parameters:</b></dt><dd> <table border="0" cellspacing="2" cellpadding="0"> <tr><td valign="top"></td><td valign="top"><em>session</em> </td><td>pointer to the MAPI session context </td></tr> <tr><td valign="top"></td><td valign="top"><em>usernames</em> </td><td>list of user names to resolve </td></tr> <tr><td valign="top"></td><td valign="top"><em>rowset</em> </td><td>resulting list of user details </td></tr> <tr><td valign="top"></td><td valign="top"><em>props</em> </td><td>resulting list of resolved names </td></tr> <tr><td valign="top"></td><td valign="top"><em>flaglist</em> </td><td>resulting list of resolution status (see below) </td></tr> <tr><td valign="top"></td><td valign="top"><em>flags</em> </td><td>if set to MAPI_UNICODE then UNICODE MAPITAGS can be used, otherwise only UTF8 encoded fields may be returned.</td></tr> </table> </dl> Possible flaglist values are:<ol type=1> <li>MAPI_UNRESOLVED: could not be resolved</li><li>MAPI_AMBIGUOUS: resolution match more than one entry</li><li>MAPI_RESOLVED: resolution matched a single entry</li></ol> <p> <dl class="return" compact><dt><b>Returns:</b></dt><dd>MAPI_E_SUCCESS on success, otherwise MAPI error.</dd></dl> <dl class="note" compact><dt><b>Note:</b></dt><dd>Developers may also call <a class="el" href="IUnknown_8c.html#8237c7fc76377cb07f3f55920d6f20de">GetLastError()</a> to retrieve the last MAPI error code. Possible MAPI error codes are:<ol type=1> <li>MAPI_E_NOT_INITIALIZED: MAPI subsystem has not been initialized</li><li>MAPI_E_SESSION_LIMIT: No session has been opened on the provider</li><li>MAPI_E_NOT_ENOUGH_RESOURCES: MAPI subsystem failed to allocate the necessary resources to operate properly</li><li>MAPI_E_NOT_FOUND: No suitable profile database was found in the path pointed by profiledb</li><li>MAPI_E_CALL_FAILED: A network problem was encountered during the transaction</li></ol> </dd></dl> <dl class="see" compact><dt><b>See also:</b></dt><dd>MAPILogonProvider, <a class="el" href="IUnknown_8c.html#8237c7fc76377cb07f3f55920d6f20de">GetLastError</a> </dd></dl> <p>References <a class="el" href="nspi_8c_source.html#l01042">nspi_ResolveNames()</a>, and <a class="el" href="nspi_8c_source.html#l01107">nspi_ResolveNamesW()</a>.</p> <p>Referenced by <a class="el" href="simple__mapi_8c_source.html#l00461">AddUserPermission()</a>, <a class="el" href="IABContainer_8c_source.html#l00187">GetABRecipientInfo()</a>, <a class="el" href="simple__mapi_8c_source.html#l00530">ModifyUserPermission()</a>, and <a class="el" href="simple__mapi_8c_source.html#l00643">RemoveUserPermission()</a>.</p> </div> </div><p> </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>