Wrox Programmer Forums
Go Back   Wrox Programmer Forums > Visual Basic > VB 6 Visual Basic 6 > VB.NET
|
VB.NET General VB.NET discussions for issues that don't fall into other VB.NET forums.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the VB.NET section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old December 6th, 2003, 02:00 AM
Registered User
 
Join Date: Dec 2003
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default Connecting to an MS Exchange Server from VB .NET

hi,

I have a Windows Service written in VB .NET which connects to an Exchange Server and accesses the messages in the Public Folders. I am using Collaborative Data Objects to do this. When I run the service, I get the following error...

System.Runtime.InteropServices.COMException (0x80010106): [Collaboration Data Objects - [UNKNOWN_ERROR(80010106)]] at System.RuntimeType.ForwardCallToInvokeMember(Strin g memberName, BindingFlags flags, Object target, Int32[] aWrapperTypes, MessageData& msgData) at MAPI.SessionClass.Logon(Object ProfileName, Object ProfilePassword, Object ShowDialog, Object NewSession, Object ParentWindow, Object NoMail, Object ProfileInfo) at EMailParser.EMailParser.EmailApp()

My logon method looks like this ...

oSession = New MAPI.Session

'** Logon to the Exchange Server **'
Try
oSession.Logon(, , , , , , server & vbLf & user)
Catch e As System.Runtime.InteropServices.COMException
EventLog1.WriteEntry(e.ToString())
End Try

Here "server" is the name of the Exchange Server and "user" is name of the mailbox account on the exchange server. This piece of code works perfectly on one exchange server and does what it is supposed to do but when it is run on another exchange server, it throws the above error. Both the exchange servers are running Service Pack 3.

Details about the error as obtained from the event viewer...

Event Type: Information
Event Source: MySource
Event Category: None
Event ID: 0
Date: 11/12/2003
Time: 11:11:28 AM
User: N/A
Computer: E2K1
Description:
System.Runtime.InteropServices.COMException (0x80010106): [Collaboration Data Objects - [UNKNOWN_ERROR(80010106)]]
at System.RuntimeType.ForwardCallToInvokeMember(Strin g memberName, BindingFlags flags, Object target, Int32[] aWrapperTypes, MessageData& msgData)
at MAPI.SessionClass.Logon(Object ProfileName, Object ProfilePassword, Object ShowDialog, Object NewSession, Object ParentWindow, Object NoMail, Object ProfileInfo)
at EMailParser.EMailParser.EmailApp()
 
Old February 27th, 2005, 10:05 PM
Registered User
 
Join Date: Feb 2005
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default

I was wondering if you ever got this to work and if so could you show what you did?

 
Old February 27th, 2008, 02:16 PM
Registered User
 
Join Date: Feb 2008
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Did you got this working. .I am still struggling

 
Old January 31st, 2011, 07:37 AM
Registered User
 
Join Date: Jan 2011
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Better option is to use WebDAV protocol. You can also look at WebDAV .NET for Exchange, a component for .NET that makes it easy to work with WebDAV. documents





Similar Threads
Thread Thread Starter Forum Replies Last Post
VB.Net with Exchange Server 2003 kbc VB.NET 3 January 8th, 2009 01:45 PM
vb.net connecting to server waad VB Databases Basics 1 December 18th, 2007 04:17 PM
MS Exchange Server+Intranet: best practice? klaf_bang .NET Web Services 0 October 22nd, 2007 08:09 AM
Connecting database using ms access and vb.net adil_farooq Access 0 October 27th, 2005 11:54 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.