SYMPTOMS
When attempting to use Collaboration Data Objects (CDO) 1.21, you receive the following error message:
MAPI_E_FAILONEPROVIDER (8004011D).
If you are accessing CDO 1.21 from an Active Server Pages page (ASP) you might receive the following error message:
Active Messaging error '00000505'
You do not have permission to log on. [Microsoft Exchange Server
Information Store - [MAPI_E_FAILONEPROVIDER(8004011D)]]
There are a number of reasons why this error message appears. This article
discusses some of the causes and resolutions.
RESOLUTION
The following resolutions match the causes listed in the previous section.
Cause 1: Resolution
If you are using the IIS anonymous account to access an Exchange account,
these items need to be set up as follows on the IIS computer and the
Exchange server:
- The virtual directory that the script is being run from must
have the correct anonymous account associated with it, along
with the correct password. Access the Web page's properties by
right-clicking on the directory in MMC and selecting Properties.
Select the Directory Security tab and click Edit under
Anonymous Access and Authentication Control. Make sure that the
Enable Password Synchronization check box is not selected and fill in
the DOMAIN\UserID and Password of the Windows NT account that is
associated with the mailbox you want to access.
- The account that you set up on the Exchange mailbox (the same
account specified in the previous bullet) must have Send As or Owner
rights to the mailbox.
- The account specified above must have rights to Log On Locally to the
IIS computer. You can set these rights through the User Manager.
For more information on how to configure Exchange and IIS for anonymous
access, please see the following article in the Microsoft Knowledge Base:
195681
HOWTO: Configure an Exchange Mailbox for Anonymous Access
Cause 2: Resolution
A difference between viewing Public Folders from Visual Basic and from
Visual Basic Script in an ASP page is that in Visual Basic Script you need
to use the GetFolder() method, which means you need to know the FolderID.
If you do not know the FolderID, you need to determine the FolderID
programmatically.
For an example of how to access public folders from an ASP, please see the
following article in the Microsoft Knowledge Base:
178552
HOWTO: View Public Folder Contents from an ASP
Cause 3: Resolution
Your authentication control is set to "NT Challenge Response," and you are
using Netscape Navigator for your browser. Netscape Navigator does not
support "NT Challenge Response" as an authentication option. To log on to a
user's Exchange account using Netscape Navigator as your browser, you need
to set up the IIS authentication as "Basic (Clear Text)".
Cause 4: Resolution
You need to verify the following to ensure that proper permissions are set
on the Exchange Server. For simplicity, this article assumes that Internet
Information Server (IIS) is on the same computer as the Exchange Server.
To determine the authentication being used by IIS for this ASP, do the
following:
Windows NT Challenge/Response or Basic Authentication:
The Windows NT user who is running the .asp page must have appropriate
permissions to the mailbox that the .asp page is logging on to. Verify that
the Exchange or Outlook clients can open the mailbox and the public folders
without being prompted for authentication.
Anonymous Access:
If you are accessing IIS as the Anonymous user, you should either log on to
the Exchange Server as an Anonymous user or follow the steps in the
following article in the Microsoft Knowledge Base:
179332
HOWTO: Programmatically Gain Anonymous Access to Public
Folders
To logon to Exchange as an anonymous user, please see the instructions in
the Remarks section of the Platform SDK/CDO (1.x) article entitled "Logon Method (Session Object)" in the Microsoft Developer Network (MSDN) Library.
For sample code to help you determine what authentication level and user
account is in use, please see the following article in the Microsoft
Knowledge Base:
189533
PRB: MAPI_E_FAILONEPROVIDER Accessing Public Folder
Through ASP
Cause 5: Resolution
If you are using a Windows 95 client, you might be trying to access any
InfoStore related properties or methods except the AddressBook.
When using Collaboration Data Objects 1.21 with the ProfileInfo Logon parameter on Windows 95, access to the Store fails because the Emsmdb.dll file cannot handle a separate Remote Procedure Call (RPC) connection when running on Windows 95.
Emsmdb.dll is the service provider loaded by the Messaging Application Programming Interface (MAPI) session in order to communicate with the Exchange Server.
Use one of the following methods to work around this:
- If possible, do not use the ProfileInfo parameter to log on.
- Make sure that the MAPI Spooler is not running at the time that this is
executed. The MAPI spooler is normally launched by the Outlook or
Exchange Clients, and does not shut down immediately after the
client is shut down.
For more information on this issue, please see the following article in the
Microsoft Knowledge Base:
183093
FIX: MAPI_E_FAILONEPROVIDER Using Store Related
Properties w/CDO