Eileen J O'Rourke

Mar 16, 2012 at 7:06 PM

I am using the March 2012 release of MFCMapi and I am running into an issue where I am getting the error code 0x800005 when I try to expand the mailbox.

Below is the Exchange powershell that I ran in my test lab, taken from the following BlackBerry article:

  Assigning service account permissions for a BlackBerry Enterprise Server for Microsoft Exchange
  http://btsc.webapps.blackberry.com/btsc/search.do?cmd=displayKC&docType=kc&externalId=KB02276

For Microsoft Exchange Server 2010
1. Click Start > Programs > Microsoft Exchange Server 2010 > Exchange Management Shell.
2. Open the command prompt as administrator, type the following line and then press ENTER:

Get-MailboxDatabase | Add-ADPermission -User "BESAdmin" -AccessRights ExtendedRight -ExtendedRights Receive-As, ms-Exch-Store-Admin

Outcome #1:
On a Windows Server 2008 R2 with Service Pack 1 (no Exchange 2010) with Office 2010 installed using a test mailbox - AzMailman - and MFCMapi 32-bit version the test mailbox is able open any of the other user mailboxes.

Outcome #2:
On an Exchange Server 2010 SP1 RU6 and the most recent Microsoft Exchange Server MAPI Client and Collaboration Data Objects 1.2.1 downloaded (http://www.microsoft.com/download/en/details.aspx?displaylang=en&id=1004) and installed, I get the MAPI error 0x8007005 when I attempt to open the same test mailbox as I did on the Domain Controller in Outcome #1 above.

I made the following changes to my test account AzMailMan and I can now logon to its own mailbox and any other user mailboxes using Outlook 2010.
 
1. Ran the Powershell script below to grant AzMailBox full access permission within Store.

$CorpMailboxes = Get-Mailbox -Database CORP
$CorpMailboxes | Foreach-Object {Add-MailboxPermission -identity $_.Name -user contoso\azmailman -AccessRights FullAccess,ExternalAccount -InheritanceType All -Automapping $False}

2. I tried MFCMapi with the AzMailMan account on the Exchange 2010 server and it still failed with the error 0x8007005 when opening the AzMailMan mailbox.
3. I then added the AzMailMan account to the Domain Admins group and restarted the Exchange Information Store service.
4. I then logged off of the Exchange 2010 Hub/CAS server and logged back in with the Domain Admin account.
5. I tried MFCMapi with the AzMailMan account and again I failed with the 0x8007005 MAPI error the AzMailMan mailbox.
6. Then I logged off of the Exchange 2010 Hub/CAS server and logged back in as the contoso\AzMailMan account.
7. I ran MFCMapi and still failed with the 0x8007005 MAPI error.
8. Then I ran MFCMapi using the "Run as administartor" while logged in as the contoso\AzMailMan account and this time it worked! I was granted access to the contoso\AzMailMan mailbox and I could open up any other mailbox.

Even weirder than that.
As soon as I added the test user account to the Domain Admins group the attribute,adminCount switched from <not set> to a value of 1.
I have noted that when I log on using the contoso\AzMailMan domain admin crendials and then run the MACMapi.exe using "Run as administrator" then the Resource Flag for the Mailbox is 4102.
But if I logon ad contoso\administrator and select "Run as administrator" and then run MFCMAPI.exe using the AzMailMan MAPI profile I get a different Resource Flag for the mailbox, 6150.
I only conclude from this is that Resource Flag of 4102 = working and resource Flag of 6150 = Epic Fail.

So my ask is this:

1. Do I always have to use the “Run as Administrator” option when  running MFCMapi on an Exchange 2010 server or am I missing something?
2. Is there any documentation on what the Resource Flag codes mean?

TIA –
Eileen J O’Rourke

Coordinator
Mar 16, 2012 at 7:18 PM

Eileen - your error codes are missing a digit. Are you getting 0x80070005 (MAPI_E_NO_ACCESS) or are you getting 0x80070057 (MAPI_E_INVALID_PARAMETER)? What is Resource Flag? Where are you reading that?

1 - As far as I know, no one else has to - this is unusual.

2 - Tell me where you found it and I'll see if I can tell you what it means.

Mar 16, 2012 at 7:29 PM
Oopsie! it is 0x80070005 (MAPI_E_NO_ACCESS).

I wanted to see if anyone else had run into this prior to me opening a case with MSFT.


From: [email removed]
To: [email removed]
Date: Fri, 16 Mar 2012 12:18:17 -0700
Subject: Re: Eileen J O'Rourke [MFCMAPI:348938]

From: sgriffin
Eileen - your error codes are missing a digit. Are you getting 0x80070005 (MAPI_E_NO_ACCESS) or are you getting 0x80070057 (MAPI_E_INVALID_PARAMETER)? What is Resource Flag? Where are you reading that?
1 - As far as I know, no one else has to - this is unusual.
2 - Tell me where you found it and I'll see if I can tell you what it means.
Read the full discussion online.
To add a post to this discussion, reply to this email (MFCMAPI@discussions.codeplex.com)
To start a new discussion for this project, email MFCMAPI@discussions.codeplex.com
You are receiving this email because you subscribed to this discussion on CodePlex. You can unsubscribe on CodePlex.com.
Please note: Images and attachments will be removed from emails. Any posts to this discussion will also be available online at CodePlex.com
Mar 16, 2012 at 7:36 PM
Sorry, forgot to attach pictures
The Resource Flag is one of the columns in the Output Table


From: [email removed]
To: [email removed]
Date: Fri, 16 Mar 2012 12:18:17 -0700
Subject: Re: Eileen J O'Rourke [MFCMAPI:348938]

From: sgriffin
Eileen - your error codes are missing a digit. Are you getting 0x80070005 (MAPI_E_NO_ACCESS) or are you getting 0x80070057 (MAPI_E_INVALID_PARAMETER)? What is Resource Flag? Where are you reading that?
1 - As far as I know, no one else has to - this is unusual.
2 - Tell me where you found it and I'll see if I can tell you what it means.
Read the full discussion online.
To add a post to this discussion, reply to this email (MFCMAPI@discussions.codeplex.com)
To start a new discussion for this project, email MFCMAPI@discussions.codeplex.com
You are receiving this email because you subscribed to this discussion on CodePlex. You can unsubscribe on CodePlex.com.
Please note: Images and attachments will be removed from emails. Any posts to this discussion will also be available online at CodePlex.com
Coordinator
Mar 16, 2012 at 7:41 PM

You'll need to host your picture and link to it. You can't mail it to codeplex.