I am getting a MAPI error 0x80070057 (E_INVALIDARG) error calling
GetMailboxTable after I have Office 2003 installed. MS Office XP used to
have problem with this method and they fixed it in OXP SP1. The code worked
with every other version of Office. It's clear to me that something changed
in Office 2003. Anyone can shed light on how to get the code going?
Eventually, it's clear to me that I need to drop that MAPI stuff, but
Exchange 5.5 is still around...
Thanks!
XC
// create profile stuff
hr = MAPILogonEx(0, (LPTSTR)rcProfile, NULL,
MAPI_NEW_SESSION| MAPI_EXTENDED |MAPI_NO_MAIL | MAPI_NT_SERVICE,
&m_pSession);
if (FAILED(hr))
{
// error handling
}
// only have general error codes.
hr =HrOpenExchangePrivateStore(m_pSession, &m_pMsgStore);
if (FAILED (hr))
{
// error handling
}
if(S_OK != m_pMsgStore->QueryInterface(IID_IExchangeManageStore,(LPVOID*)
&m_pExManageStore))
{
// error handling
}
// grab the server, site,org names in ANSI
sprintf(rpServerDN,"/o=%s/ou=%s/cn=servers/cn=%s", rpOrg, rpSite,
rpServer);
IMAPITablePtr pMAPITable;
hr = m_pExManageStore->GetMailboxTable(rpServerDN, &pMAPITable, 0);
...
"abc5594def" <som...@somewhere.com> wrote in message
news:eakA8rv...@TK2MSFTNGP10.phx.gbl...
Dmitry Streblechenko (MVP)
http://www.dimastr.com/
OutlookSpy - Outlook, CDO
and MAPI Developer Tool
"Huaxc" <xing...@netiq.com> wrote in message
news:%23wTxHpU...@TK2MSFTNGP09.phx.gbl...
Xingcheng
"Dmitry Streblechenko" <dmi...@dimastr.com> wrote in message
news:%23eUEK1U...@TK2MSFTNGP09.phx.gbl...