PC Review


Reply
Thread Tools Rate Thread

Did not receive email via CDO.message

 
 
Eka1618
Guest
Posts: n/a
 
      11th Aug 2008
Hello,

I am trying to set up an e-mail message using the code below. When I call
the function, I think the message sends, but I do not know where to find
it....

I am sending myself an email to test out the code. I currently use Outlook
so I would assume that the message should be reveieved there, however, I
never got it.

I was using a script that used the Microsoft Outlook 12.0 reference library,
but I could not seem to get rid of the "send email on behalf of" warning on
PC's using the runtime version of Access 2007. I am trying this new method,
but I do not know much about it and I do not know where the email went.

If anyone knows what I can do, please let me know, Thank You!

Sub sndEmail()

Dim iMsg
Dim iConf
Dim Flds
Dim strHTML
'Dim iBp As CDO.IBodyPart
'Dim iMsg As New CDO.Message

Const cdoSendUsingPort = 2

Set iMsg = CreateObject("CDO.Message")
Set iConf = CreateObject("CDO.Configuration")

Set Flds = iConf.Fields


With Flds
'.Item("http://schemas.microsoft.com/cdo/configuration/sendusing") =
cdoSendUsingPort
.Item(cdoSendUsingMethod) = cdoSendUsingPort
.Item(cdoSMTPServerPort) = 25
.Item("http://schemas.microsoft.com/cdo/configuration/smtpserver") =
"mcg144.NTDOMAIN.COM"

..Item("http://schemas.microsoft.com/cdo/configuration/smtpconnectiontimeout")
= 10
.Update
End With


With iMsg
Set .Configuration = iConf
.To = CurrentDb.Properties("RequestorEmail")
'.CC = "(E-Mail Removed)"
.From = CurrentDb.Properties("RequesteeEmail")
.Subject = emailSubject
.HTMLBody = "<h2 align = center><b><font color = red>Product Test
Request Due Date Changed (Test Requestor Next
Action)</font></b></h2><br><br>" & emailBody
.Send
End With

Set iMsg = Nothing
Set iConf = Nothing
Set Flds = Nothing

End Sub

--
~Erica~
 
Reply With Quote
 
 
 
 
Eka1618
Guest
Posts: n/a
 
      12th Aug 2008
The company I work for is blocking the e-mails that I send out this way. I
think it is a setting on Windows. It says that the e-mails are spam...

--
~Erica~


"Eka1618" wrote:

> Hello,
>
> I am trying to set up an e-mail message using the code below. When I call
> the function, I think the message sends, but I do not know where to find
> it....
>
> I am sending myself an email to test out the code. I currently use Outlook
> so I would assume that the message should be reveieved there, however, I
> never got it.
>
> I was using a script that used the Microsoft Outlook 12.0 reference library,
> but I could not seem to get rid of the "send email on behalf of" warning on
> PC's using the runtime version of Access 2007. I am trying this new method,
> but I do not know much about it and I do not know where the email went.
>
> If anyone knows what I can do, please let me know, Thank You!
>
> Sub sndEmail()
>
> Dim iMsg
> Dim iConf
> Dim Flds
> Dim strHTML
> 'Dim iBp As CDO.IBodyPart
> 'Dim iMsg As New CDO.Message
>
> Const cdoSendUsingPort = 2
>
> Set iMsg = CreateObject("CDO.Message")
> Set iConf = CreateObject("CDO.Configuration")
>
> Set Flds = iConf.Fields
>
>
> With Flds
> '.Item("http://schemas.microsoft.com/cdo/configuration/sendusing") =
> cdoSendUsingPort
> .Item(cdoSendUsingMethod) = cdoSendUsingPort
> .Item(cdoSMTPServerPort) = 25
> .Item("http://schemas.microsoft.com/cdo/configuration/smtpserver") =
> "mcg144.NTDOMAIN.COM"
>
> .Item("http://schemas.microsoft.com/cdo/configuration/smtpconnectiontimeout")
> = 10
> .Update
> End With
>
>
> With iMsg
> Set .Configuration = iConf
> .To = CurrentDb.Properties("RequestorEmail")
> '.CC = "(E-Mail Removed)"
> .From = CurrentDb.Properties("RequesteeEmail")
> .Subject = emailSubject
> .HTMLBody = "<h2 align = center><b><font color = red>Product Test
> Request Due Date Changed (Test Requestor Next
> Action)</font></b></h2><br><br>" & emailBody
> .Send
> End With
>
> Set iMsg = Nothing
> Set iConf = Nothing
> Set Flds = Nothing
>
> End Sub
>
> --
> ~Erica~

 
Reply With Quote
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Why this error message yet I can still send and receive some email =?Utf-8?B?SmVuIGluIFN0IExvdWlz?= Windows Vista Mail 3 18th Sep 2007 08:51 PM
Cannot receive email. Get error message: =?Utf-8?B?TmVsbG8=?= Microsoft Outlook Discussion 0 15th Jan 2007 02:54 AM
when i receive an email there is no text in the message =?Utf-8?B?SGFuayBIb29nbGFuZA==?= Microsoft Outlook Discussion 1 25th May 2006 01:19 PM
Why does Outlook2003 fail to Receive email message with Cox? =?Utf-8?B?Q2hyaXNMZWU=?= Microsoft Outlook Discussion 0 21st May 2005 05:40 AM
Do not receive email unless I start to create a new message. Bob Microsoft Outlook 1 23rd Mar 2004 01:24 AM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 06:44 AM.