email not sent Handler

chacal

Registered User.
Local time
Today, 14:22
Joined
Jun 1, 2005
Messages
40
Hi everyone,

I coded a function to send emails via Access, and it works fine. But I'd like to know if there's a way to catch the error if the email is not sent? Is there a way to catch and handle this error in Access?

Thanks in advance for your response! :)
 
all right, I have resolved my problem!

We just have to look if the outbox is empty or not:

Code:
If OlFolder.Items.Count = 0 Then
   'Then the message has been sent.
Else
'Handle the error with a message or anything else that suit you needs 
End If

Thanks anyway!
 
Last edited:

Users who are viewing this thread

Back
Top Bottom