SendMailWithOE

  • Thread starter Thread starter Bill
  • Start date Start date
B

Bill

In using Lyle Fairfield's SendMailWithOE, does OE need to
be the default e-mail client? My normal use of the function
is on machines where OE IS the default. However, I have a
user whose default e-mail client is Outlook. The function
appears to be working, at least to the extent that one is asked
for "permission" to send. Yet, no "send" takes place and no
error messages appear. A manual operation was performed
by the user, i.e., manually sent an e-mail with attachment, and
that works normally.

Any ideas on how to find the point of failure?

Thanks,
Bill
 
Bill said:
In using Lyle Fairfield's SendMailWithOE, does OE need to
be the default e-mail client? My normal use of the function
is on machines where OE IS the default. However, I have a
user whose default e-mail client is Outlook. The function
appears to be working, at least to the extent that one is asked
for "permission" to send. Yet, no "send" takes place and no
error messages appear. A manual operation was performed
by the user, i.e., manually sent an e-mail with attachment, and
that works normally.

Any ideas on how to find the point of failure?

Bill, are you sure the mail was not actually sent? Since the code is
hard-coded to use the Outlook Express DLL, at "c:\program files\outlook
express\msoe.dll", I don't see how it could fail to do so if that DLL is
installed at that location. However, that e-mail will not appear in
Outlook, because it wasn't sent using Outlook.
 
Dirk,
I concluded that msoe.dll ran as expected, since one gets the
small confirmation window to "Send" or "Do Not Send" when
SendMailWithOE runs. Two other observations confirmed, at
least in my mind, that the e-mail didn't send is that there's no
copy in the user's "Sent Item" folder in OE, an OE option that
is enabled on the user's machine, and the simple fact that I never
received the mail at my end.

I've asked the user to send me sceen-shots of the confirmation
window display plus another screen-shot of an XP search for
the msoe.dll.

I Googled for additional documentation on SendMailWithOE in
the hopes of finding some comments regarding possible problems
and how to solve them, but I didn't find any such information.

I'm racking my brain has to how I might trap the process to
look at what might be causing the failure, but it's all a "Black-Box"
to me.
Bill
 
Dirk,

User in fact has msoe.dll, as required. The screen-shots sent
do not give the slightest hint as to what might be the difficulty,
i.e., everything looks as normal as one would expect.

When I run the function on my machine, I get the OE outbox
progress bar as the e-mail gets sent out. My user doesn't see
anything like that.

I'm clueless as to what to ask of him now.

Let me know if anything pops into your mind that I might try.

Thanks,
Bill
 
Bill said:
Dirk,

User in fact has msoe.dll, as required. The screen-shots sent
do not give the slightest hint as to what might be the difficulty,
i.e., everything looks as normal as one would expect.

When I run the function on my machine, I get the OE outbox
progress bar as the e-mail gets sent out. My user doesn't see
anything like that.

I'm clueless as to what to ask of him now.

Let me know if anything pops into your mind that I might try.

I just set my default mail client to Outlook and ran a test of the
SendMailWithOE procedure, and it send the mail successfully using
Outlook Express. So that argues against the basic problem having to do
with the default mail client not being OE. Possibly your client has a
firewall set up that blocks Outlook Express? Or some other security
setting that does it? Can the client open Outlook Express directly,
create a message, and send it successfully, without replying to any
other security dialog?

One thing you could check programmatically is the return code from the
call to MAPISendMail. The version of the module I have doesn't check
that, but you could modify it so that the call is like this:

lngRC = MAPISendMail(0, 0, Message, 0, 0)

If lngRC <> 0 Then
MsgBox "Error sending mail -- return code is " & lngRC, _
vbExclamation, "SendMail Error"
End If

That might -- or might not -- tell you something.
 
Dirk Goldgar said:
One thing you could check programmatically is the return code from the
call to MAPISendMail. The version of the module I have doesn't check
that, but you could modify it so that the call is like this:

lngRC = MAPISendMail(0, 0, Message, 0, 0)

If lngRC <> 0 Then
MsgBox "Error sending mail -- return code is " & lngRC, _
vbExclamation, "SendMail Error"
End If

Note that you have to declare lngRC:

Dim lngRC As Long
 
Dirk, I've asked my client to disable his security while attempting
to use the SendMailWithOE procedure. If that doesn't offer any
answers, I'll send him an updated MDE that contains the return
code reporting you suggested.

He travels a lot, so I never know when I'll get a response. With
that, you might just flag this thread until you hear back from me, as
I'll post back as soon as I've heard anything.

Bill
 
Bill said:
Dirk, I've asked my client to disable his security while attempting
to use the SendMailWithOE procedure. If that doesn't offer any
answers, I'll send him an updated MDE that contains the return
code reporting you suggested.

He travels a lot, so I never know when I'll get a response. With
that, you might just flag this thread until you hear back from me, as
I'll post back as soon as I've heard anything.

I'll keep an eye on this thread.
 
Dirk,
My client gets a return code of "2" when SendMailWithOE (msoe.dll) runs.
I had him send me a screen-shot from "About Outlook Express" and see
that his level of msoe.dll is identical to mine, both current levels of SP2.

Do you have any idea what a return code of "2" means?

His system works fine when he creates an e-mail in OE, attaches a file
and sends.

Bill
 
PS... Are you in a USA time zone?
Bill said:
Dirk,
My client gets a return code of "2" when SendMailWithOE (msoe.dll) runs.
I had him send me a screen-shot from "About Outlook Express" and see
that his level of msoe.dll is identical to mine, both current levels of
SP2.

Do you have any idea what a return code of "2" means?

His system works fine when he creates an e-mail in OE, attaches a file
and sends.

Bill
 
Bill said:
Dirk,
My client gets a return code of "2" when SendMailWithOE (msoe.dll)
runs.
I had him send me a screen-shot from "About Outlook Express" and see
that his level of msoe.dll is identical to mine, both current levels
of SP2.

Do you have any idea what a return code of "2" means?

His system works fine when he creates an e-mail in OE, attaches a file
and sends.

This article:

http://support.microsoft.com/kb/119647/

gives what I think are the MAPI error codes, but all it says for code 2
is "MAPI_E_FAILURE", which isn't very helpful, I'm afraid. Beyond that
I have no more information at the moment.
 
Just wondering. I'm in California and sometimes when I'm
having exchanges with responders, such as yourself, I know
not to look for posts during "off" hours.
Bill
 
You're right, "MAPI_E_FAILURE" isn't much help. The other
explanations and codes offer a little more, but "this" one looks
like the programmer is saying go "punt".

I've asked the user to disable Norton and try the function again.
Actually, I thought I already had but didn't get a response. I make
sure that test gets done, as Norton sometimes blocks silently.

Bill
 
Bill said:
You're right, "MAPI_E_FAILURE" isn't much help. The other
explanations and codes offer a little more, but "this" one looks
like the programmer is saying go "punt".

I've asked the user to disable Norton and try the function again.
Actually, I thought I already had but didn't get a response. I make
sure that test gets done, as Norton sometimes blocks silently.

It wouldn't surprise me if the firewall (or maybe antivirus) is blocking
the attempt to send mail, but if the user says it was disabled, it's
hard to argue. I can't think of anything else at the moment.
 
Thanks Dirk. My user must be traveling again, as I've not heard from
him regarding the disabling of AV or firewall(s).

I'll post back with whatever I hear from him.

Bill
 
Back
Top