exchangefreaks.com Forum Index
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister   ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

CDO - Receiving New Mails

 
Post new topic   Reply to topic    exchangefreaks.com Forum Index -> MS Exchange Applications
Author Message
Trebek



Joined: 05 Aug 2007
Posts: 1

PostPosted: Thu Sep 04, 2003 3:47 pm    Post subject: CDO - Receiving New Mails Reply with quote

I apologize for the cross-post but I am uncertain which grp would be more
appropriate.

Hello group:


I have an application written in C# that retrieves messages in a user's
inbox, parses them into a SOAP request and then calls our corp webservice.
I have completed the process minus one detail which is really troubling me.
When the app is open, I periodically refresh the messages by calling
DeliverNow() of the session object, but no new messages are ever received.
Of course, if I open Outlook under the profile the application uses, the
mails are received. Then, of course, they are reflected in my application
at the next refresh.

Some info:

I am creating the session with the following method call:
Object [] args = new Object[7];
args[0] = Missing.Value; // ProfileName

args[1] = Missing.Value; // ProfilePassword

args[2] = true; // ShowDialog

args[3] = true; // NewSession

args[4] = 0; // ParentWindow

args[5] = false; // NoMail

args[6] = Missing.Value; // ProfileInfo

t.InvokeMember("Logon", BindingFlags.InvokeMethod, null,
currentSession, args);

The 'NoMail' arg is set to false so I should be linking into the mail
spooler and I do see the 'Send/Receive' dialog, so it looks like it is
trying, but no new messages ever arrive. If I attempt to forward a message
from this app, it delivers the message without issue. This is a rewrite of
my original app which was an Outlook automation program (which worked fine)
and I'm trying to duplicate my old program's functionality, but with no
success. The understanding I had from the documentation is that the
'DeliverNow' method would retrieve the 'pending' messages. Is this
incorrect? Is there something I'm missing regarding profiles?

Any advice will be much appreciated and TIA,

Alex

Archived from group: microsoft>public>dotnet>languages>csharp
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    exchangefreaks.com Forum Index -> MS Exchange Applications All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group