AlanAnderson
Board Regular
- Joined
- Jun 7, 2010
- Messages
- 134
Hi All,<?xml:namespace prefix = o ns = "urn:schemas-microsoft-comfficeffice" /><o></o>
<o></o>
The following two routines which I got from Ron de Bruin’s site have worked really well on several different machines running Excel 2003 and 2007. These machines have mostly been running various “flavours” of Windows XP><o></o>
<o></o>
I am trying to run this now on another machine using Windows 7 and Excel 2007 and it just does not work. <o></o>
<o></o>
It just drops down into the error routine <o></o>
“EMailProblem:<o></o>
MsgBox "Problem with Internet connection. These emails have probably not been sent. Check audit file and contact your support staff!"<o></o>
<o></o>
Is there something I should add / delete / change to allow for Windows 7 and/or other versions of Windows??<o></o>
<o></o>
Regards,<o></o>
<o></o>
Alan<o></o>
The followIng routine just goes straight to the following error routine:
EMailProblem:<o></o>
MsgBox "Problem with Internet connection. Do NOT attempt to send emails at this stage!"<o></o>
<o></o>
The following two routines which I got from Ron de Bruin’s site have worked really well on several different machines running Excel 2003 and 2007. These machines have mostly been running various “flavours” of Windows XP><o></o>
<o></o>
I am trying to run this now on another machine using Windows 7 and Excel 2007 and it just does not work. <o></o>
<o></o>
It just drops down into the error routine <o></o>
“EMailProblem:<o></o>
MsgBox "Problem with Internet connection. These emails have probably not been sent. Check audit file and contact your support staff!"<o></o>
<o></o>
Is there something I should add / delete / change to allow for Windows 7 and/or other versions of Windows??<o></o>
<o></o>
Regards,<o></o>
<o></o>
Alan<o></o>
Code:
<o:p></o:p>
[SIZE=3][FONT=Times New Roman]' CLIENTS/ACCOUNTS SENDING ROUTINE (USES EMAIL LIST CREATED IN FIRST ROUTINE ABOVE)<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman]Sub CDO_Mail_Small_Text2()<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] Dim vTruck As String<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] Dim vTrailer As String<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] Dim vTruckReg As String<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] Dim vName As String<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] Dim vRef As String<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] Dim vCommodity As String<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] Dim vRoute As String<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] Dim vStatus As String<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] Dim vAddress As String 'email address for client<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] Dim vAcsAddress As String 'email address for accounts<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] Dim iMsg As Object<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] Dim iConf As Object<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] Dim strbody As String<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] Dim LastRow As Long<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] Dim vFullDate As String<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] ' FOLLOWING VARIABLES REQUIRED TO SEND EMAILS. ONES MARKED 2 APPLY IN ALL CASES.IF MARKED 1 ONLY REQUIRED _<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] WHERE EMAIL PROBLEMS REQUIRE SMTP TO BE SET WITHIN ROUTINE<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] Dim vSMTP As String '1<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] Dim vServerPort As Integer '1<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] Dim vSentFromAdd As String '2<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] Dim vSentToAdd As String '2<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] Dim vSentByName As String '2<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] vServerPort = Sheets("Dates").Cells(2, 6) ‘ This value is currently set at 25<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] vSentFromAdd = Sheets("Dates").Cells(2, 8) ‘ This value is currently set at <?xml:namespace prefix = st1 ns = "urn:schemas-microsoft-com:office:smarttags" /><st1:PersonName w:st="on">afc@bdsmw.com</st1:PersonName><o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] vSentToAdd = Sheets("Dates").Cells(2, 7) ‘ This value is currently set at afctest1@bdsmw.com<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] vSentByName = Sheets("Dates").Cells(2, 9) ‘ This value is currently set at Alan<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] vSMTP = Sheets("Dates").Cells(2, 5) ‘ This value is currently set at smtp.bdsmw.com<o:p></o:p>[/FONT][/SIZE]
<o:p></o:p>
[SIZE=3][FONT=Times New Roman] ' Dim Flds As Variant<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] Dim vWho As String<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] LastRow = Sheets("eMail").Cells(Rows.Count, 2).End(xlUp).Row<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] For i = 2 To LastRow<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] <o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] vTruck = Sheets("EMail").Cells(i, 1)<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] vDriver = Sheets("EMail").Cells(i, 2)<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] vTruckReg = Sheets("EMail").Cells(i, 12)<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] vTrailer = Sheets("EMail").Cells(i, 3)<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] vName = Sheets("EMail").Cells(i, 4)<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] vRef = Sheets("EMail").Cells(i, 5)<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] vCommodity = Sheets("EMail").Cells(i, 6)<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] vRoute = Sheets("EMail").Cells(i, 7)<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] vStatus = Sheets("EMail").Cells(i, 9)<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] vContact = Sheets("EMail").Cells(i, 8)<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] vAddress = Sheets("EMail").Cells(i, 10)<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] vWho = Sheets("Email").Cells(i, 13)<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] vComments = Sheets("EMail").Cells(i, 17)<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] vFullDate = Sheets("EMail").Cells(i, 18)<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] Set iMsg = CreateObject("CDO.Message")<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] Set iConf = CreateObject("CDO.Configuration")<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] 'Following lines between XXXXXXXXXXXX are only required if regular email connection does not exist. _<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] If 25 does not work replace with 465<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] ' iConf.Load -1 ' CDO Source Defaults<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] ' Set Flds = iConf.Fields<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] ' With Flds<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] ' .Item("http://schemas.microsoft.com/cdo/configuration/sendusing") = 2<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] ' .Item("http://schemas.microsoft.com/cdo/configuration/smtpserver") _<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] ' = vSMTP ' "smtp.broadbandmw.com"<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] ' .Item("http://schemas.microsoft.com/cdo/configuration/smtpserverport") = Val(vServerPort)<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] ' .Update<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] ' End With<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] 'Above lines between XXXXXXXXXXXX are only required if regular email connection does not exist<o:p></o:p>[/FONT][/SIZE]
<o:p></o:p>
[SIZE=3][FONT=Times New Roman] strbody = "For Attention: " & vContact & vbNewLine & _<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] "Please note the following status of your load" & vbNewLine & vbNewLine & _<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] "Fleet No " & vTruck & vbNewLine & _<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] "Driver Name " & vDriver & vbNewLine & _<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] "Truck Registration " & vTruckReg & vbNewLine & _<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] "Trailer no " & vTrailer & vbNewLine & _<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] "Client Name " & vName & vbNewLine & _<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] "Client / Load Reference " & vRef & vbNewLine & _<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] "Commodity / Load " & vCommodity & vbNewLine & _<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] "Comments " & vComments & vbNewLine & _<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] "Route " & vRoute & vbNewLine & _<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] "Current Status " & vStatus & vbNewLine & _<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] "Date & Time of Position " & vFullDate & vbNewLine<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] <o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] <o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] <o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman]On Error GoTo EMailProblem<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] With iMsg<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] Set .Configuration = iConf<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] ' .To = "<st1:PersonName w:st="on">afc@bdsmw.com</st1:PersonName>"<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] .To = vAddress<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] .CC = ""<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] .BCC = ""<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] .From = vSentByName & " <" & vSentFromAdd & ">"<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] .Subject = "Current Status of load. Client Reference: ....." & " " & vRef<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] .TextBody = strbody<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] .Send<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] End With<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] Dim vToday As Date<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] vToday = Now<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] <o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] ' vToday = Format(Now, "MMDDYYYY HHMM")<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] WriteRowAudit = Sheets("EMailAudit").Cells(Rows.Count, 1).End(xlUp).Row + 1<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] Sheets("EMailAudit").Cells(WriteRowAudit, 1).Value = vTruck<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] Sheets("EMailAudit").Cells(WriteRowAudit, 2) = vDriver<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] Sheets("EMailAudit").Cells(WriteRowAudit, 3) = vTrailer<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] Sheets("EMailAudit").Cells(WriteRowAudit, 4) = vName<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] Sheets("EMailAudit").Cells(WriteRowAudit, 5) = vRef<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] Sheets("EMailAudit").Cells(WriteRowAudit, 6) = vCommodity<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] Sheets("EMailAudit").Cells(WriteRowAudit, 7) = vRoute<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] Sheets("EMailAudit").Cells(WriteRowAudit, 8) = vStatus<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] Sheets("EMailAudit").Cells(WriteRowAudit, 9) = vContact<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] Sheets("EMailAudit").Cells(WriteRowAudit, 14) = vEMail<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] Sheets("EMailAudit").Cells(WriteRowAudit, 11) = vToday 'date<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] Sheets("EMailAudit").Cells(WriteRowAudit, 12) = vWho 'Ac/Cl<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] Sheets("EMailAudit").Cells(WriteRowAudit, 13) = vTruckReg<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] Sheets("EMailAudit").Cells(WriteRowAudit, 10) = vAddress<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] Sheets("EMailAudit").Cells(WriteRowAudit, 15) = vComments<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman]Next i<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman]GoTo RtnEnd<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman]EMailProblem:<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] MsgBox "Problem with Internet connection. These emails have probably not been sent. Check audit file and contact your support staff!"<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman]GoTo endprg<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman]RtnEnd:<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman]MsgBox "EMail connection seems in order. EMails sent"<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman]endprg:<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman]End Sub<o:p></o:p>[/FONT][/SIZE]
The followIng routine just goes straight to the following error routine:
EMailProblem:<o></o>
MsgBox "Problem with Internet connection. Do NOT attempt to send emails at this stage!"<o></o>
Code:
[SIZE=3][FONT=Times New Roman]Sub CDO_Mail_Test()<o:p></o:p>[/FONT][/SIZE]
<o:p></o:p>
[SIZE=3][FONT=Times New Roman] Dim iMsg As Object<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] Dim iConf As Object<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] Dim strbody As String<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] <o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] ' FOLLOWING VARIABLES REQUIRED TO SEND EMAILS. ONES MARKED 2 APPLY IN ALL CASES.IF MARKED 1 ONLY REQUIRED _<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] WHERE EMAIL PROBLEMS REQUIRE SMTP TO BE SET WITHIN ROUTINE<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] Dim vSMTP As String '1<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] Dim vServerPort As Integer '1<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] Dim vSentFromAdd As String '2<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] Dim vSentToAdd As String '2<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] Dim vSentByName As String '2<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] vServerPort = Sheets("Dates").Cells(2, 6)<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] vSentFromAdd = Sheets("Dates").Cells(2, 8)<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] vSentToAdd = Sheets("Dates").Cells(2, 7)<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] vSentByName = Sheets("Dates").Cells(2, 9)<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] vSMTP = Sheets("Dates").Cells(2, 5)<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] Set iMsg = CreateObject("CDO.Message")<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] Set iConf = CreateObject("CDO.Configuration")<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] <o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman]'Following lines between XXXXXXXXXXXX are only required if regular email connection does not exist If 25 does not work replace with 465<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman]' iConf.Load -1 ' CDO Source Defaults<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman]' Set Flds = iConf.Fields<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman]' With Flds<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman]' .Item("http://schemas.microsoft.com/cdo/configuration/sendusing") = 2<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman]' .Item("http://schemas.microsoft.com/cdo/configuration/smtpserver") _<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman]' = vSMTP ' "smtp.broadbandmw.com"<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman]' .Item("http://schemas.microsoft.com/cdo/configuration/smtpserverport") = Val(vServerPort)<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman]' .Update<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman]' End With<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman]'Above lines between XXXXXXXXXXXX are only required if regular email connection does not exist<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] strbody = "EMail Correct - Proceed to next option"<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman]On Error GoTo EMailProblem<o:p></o:p>[/FONT][/SIZE]
<o:p></o:p>
[SIZE=3][FONT=Times New Roman] With iMsg<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] Set .Configuration = iConf<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] ' .To = "<st1:PersonName w:st="on">afc@bdsmw.com</st1:PersonName>"<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] .To = vSentToAdd<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] .CC = ""<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] .BCC = ""<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] .From = vSentByName & " <" & vSentFromAdd & ">" ' """Derek"" <DEREK@BROADBANDMW.COM>"<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] .Subject = "EMail Status "<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] .TextBody = strbody<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] .Send<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] End With<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman]GoTo RtnEnd<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman]EMailProblem:<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] MsgBox "Problem with Internet connection. Do NOT attempt to send emails at this stage!"<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman] GoTo endprg<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman]RtnEnd:<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman]MsgBox "EMail connection seems in order. Proceed to send eMails"<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman]endprg:<o:p></o:p>[/FONT][/SIZE]
[SIZE=3][FONT=Times New Roman]End Sub<o:p></o:p>[/FONT][/SIZE]
<o:p></o:p>
<o:p></o:p>
<o:p></o:p>
<o:p></o:p>