Advertisement

02.20.2006 at 02:33AM PST, ID: 21743533
[x]
Attachment Details

Logon into exchange

Asked by micstan in Exchange Email Server

Tags: connected, exchange, mapi

I'm trying to logon into Exchange Server but it fails everytime.

I'm using with reference to CDO 1.21 liberary.
I have a few lines of code on the client machine, which is operate as Admin.
Dim oSession As MAPI.Session
   ReDim aMailboxList(1) As String
   ReDim aserverlist(1) As String
   Dim iBigLoop As Integer

   Dim sServerName As String
   Dim sProfileInfo As String
   Dim sMailboxName As String


   'TO DO: Change "ServerName" to the name of your Exchange Server
   sServerName = "yudkevich.co.il"

   'TO DO: Change "MailboxName" to the name of a mailbox on the
   '  server specified above
   sMailboxName = "Mailbox - Administrator"
   sProfileInfo = sServerName & vbLf & sMailboxName

   Set oSession = CreateObject("MAPI.Session")
   oSession.Logon profileinfo:=sProfileInfo         <<--- it fails over here

and then i'm getting a message
"Outlook code not log on. check to make sure your are connected to the network and are using the proper server and mailbox name. the connection to the MIcrosoft Exchange Server is unavailable. outlook must be online or connected to complete this action"

I'm pressing ok, and getting a message that says "run time error ... MAPI_E_LOGON_FAILED...
I know that the mailbox exists and this is the name of the Exchange Server. so what is going on ????????
RafiStart Free Trial
[+][-]02.20.2006 at 06:56AM PST, ID: 16000371

View this solution now by starting your 7-day free trial. Setting up your free trial is quick, easy, and secure. We will return you to this solution, unlocked, when you're done.

 

About this solution

Zone: Exchange Email Server
Tags: connected, exchange, mapi
Sign Up Now!
Solution Provided By: LeeDerbyshire
Participating Experts: 2
Solution Grade: B
 
 
[+][-]02.20.2006 at 07:05AM PST, ID: 16000474

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
 
Loading Advertisement...
20080716-EE-VQP-32