|
 |
asp_cdo thread: Problems with Connecting to Exchange Server From IIS 5.1/ASP
Message #1 by "Chad A. Beckner" <cbeckner@i...> on Tue, 26 Feb 2002 15:28:38
|
|
I have an ASP Script that uses a MAPI.Session to connect to our Exchange
Server. I had developed the script on IIS 5.0 with Office 2000 installed,
and it worked just fine (I have a test machine with this setup, and it
works fine). When I copy the script to a machine running Windows XP (IIS
5.1) and Office XP installed, the script does not work, and I get this
error message:
************************************************************
The page cannot be displayed There is a problem with the page you are
trying to reach and it cannot be displayed.
---------------------------------------------------------------------------
-----
Please try the following:
Click the Refresh button, or try again later.
Open the home page, and then look for links to the information you want.
HTTP 500.100 - Internal Server Error - ASP error Internet Information
Services
---------------------------------------------------------------------------
-----
Technical Information (for support personnel)
Error Type: Collaboration Data Objects (0x505) The Microsoft Exchange
Server computer is not available. Either there are network problems or the
Microsoft Exchange Server computer is down for maintenance. [Microsoft
Exchange Server Information Store - [MAPI_E_FAILONEPROVIDER
(8004011D)]] /Default.asp, line 33
Browser Type: Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; Q312461)
Page: GET /Default.asp
Time: Tuesday, February 26, 2002, 8:37:14 AM
More information: Microsoft Support
************************************************************
Here is the code that I am using to connect and intitiate the MAPI
session. I have edited out the ServerName and Mailbox for this posting.
************************************************************
@ LANGUAGE="VBSCRIPT"
Profile_Info = "" + vbLf + ""
Const CdoDefaultFolderTasks = 8
Set objSession = Server.CreateObject("MAPI.Session")
objSession.Logon , , , true, , true, Profile_Info
Set ObjFolder = objSession.GetDefaultFolder(CdoDefaultFolderTasks)
Set TaskList = ObjFolder.Messages
************************************************************
It seems to make the connection to Exchange, but when I try "Set TaskList
= ...", it comes back with the above error message.
Does anyone have any idea of what might be wrong?! Any help would be
greatly appreciated!
Thanks for your time!
- Chad
Message #2 by "Siegfried Weber" <sweber@c...> on Thu, 28 Feb 2002 15:55:28 +0100
|
|
Well, I don't know why it worked on the other machine but your code has
a major problem. You are trying to connect to an Exchange mailbox
without supplying a valid Exchange server name and mailbox alias here:
Profile_Info =3D "" + vbLf + ""
This will always produce an error at the moment you are trying to access
any data in the mailbox.
You need to provide a valid Exchange Server and mailbox alias in the
above parameter and make sure your code uses a Windows NT/2000 account
which actually has owner permissions to open this particular mailbox.
<Siegfried />
> -----Original Message-----
> From: Chad A. Beckner [mailto:cbeckner@i...]
> Sent: Tuesday, February 26, 2002 4:29 PM
> To: ASP CDO
> Subject: [asp_cdo] Problems with Connecting to Exchange Server From
IIS
> 5.1/ASP
>
> I have an ASP Script that uses a MAPI.Session to connect to our
Exchange
> Server. I had developed the script on IIS 5.0 with Office 2000
installed,
> and it worked just fine (I have a test machine with this setup, and it
> works fine). When I copy the script to a machine running Windows XP
(IIS
> 5.1) and Office XP installed, the script does not work, and I get this
> error message:
>
> ************************************************************
>
> The page cannot be displayed There is a problem with the page you are
> trying to reach and it cannot be displayed.
>
>
------------------------------------------------------------------------
--
> -
> -----
>
> Please try the following:
>
> Click the Refresh button, or try again later.
>
> Open the home page, and then look for links to the information you
want.
> HTTP 500.100 - Internal Server Error - ASP error Internet Information
> Services
>
>
------------------------------------------------------------------------
--
> -
> -----
>
> Technical Information (for support personnel)
>
> Error Type: Collaboration Data Objects (0x505) The Microsoft Exchange
> Server computer is not available. Either there are network problems or
the
> Microsoft Exchange Server computer is down for maintenance. [Microsoft
> Exchange Server Information Store - [MAPI_E_FAILONEPROVIDER
> (8004011D)]] /Default.asp, line 33
>
> Browser Type: Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1;
Q312461)
>
> Page: GET /Default.asp
>
> Time: Tuesday, February 26, 2002, 8:37:14 AM
>
> More information: Microsoft Support
>
> ************************************************************
>
> Here is the code that I am using to connect and intitiate the MAPI
> session. I have edited out the ServerName and Mailbox for this
posting.
>
> ************************************************************
> @ LANGUAGE=3D"VBSCRIPT"
> Profile_Info =3D "" + vbLf + ""
>
> Const CdoDefaultFolderTasks =3D 8
> Set objSession =3D Server.CreateObject("MAPI.Session")
> objSession.Logon , , , true, , true, Profile_Info
> Set ObjFolder =3D objSession.GetDefaultFolder(CdoDefaultFolderTasks)
> Set TaskList =3D ObjFolder.Messages
>
> ************************************************************
>
> It seems to make the connection to Exchange, but when I try "Set
TaskList
> =3D ...", it comes back with the above error message.
>
> Does anyone have any idea of what might be wrong?! Any help would be
> greatly appreciated!
>
> Thanks for your time!
>
> - Chad
$subst('Email.Unsub').
|
|
 |