Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I'm getting an error when I am using this macro:
Sub AA_CDO() Dim iMsg As Object Dim iConf As Object ' Dim Flds As Variant Set iMsg = CreateObject("CDO.Message") Set iConf = CreateObject("CDO.Configuration") ' iConf.Load -1 ' CDO Source Defaults ' Set Flds = iConf.Fields ' With Flds ' ..Item("http://schemas.microsoft.com/cdo/configuration/sendusing") = 2 ' ..Item("http://schemas.microsoft.com/cdo/configuration/smtpserver") = " ' ..Item("http://schemas.microsoft.com/cdo/configuration/smtpserverport") = 25 ' .Update ' End With With iMsg Set .Configuration = iConf .To = ; " .CC = " .BCC = "" .From = """Excel"" " .Subject = "Important message" .TextBody = "AA has reached its stop loss" & vbNewLine & vbNewLine & _ "Please review this position immediately." .Send End With Set iMsg = Nothing Set iConf = Nothing End Sub Any thoughts? |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Have you read all information on my site ??
http://www.rondebruin.nl/cdo.htm I see that you not use the commented lines and i see a strange name for the SMTP server -- Regards Ron de Bruin http://www.rondebruin.nl/tips.htm "Macro not running as intended" om wrote in message ... I'm getting an error when I am using this macro: Sub AA_CDO() Dim iMsg As Object Dim iConf As Object ' Dim Flds As Variant Set iMsg = CreateObject("CDO.Message") Set iConf = CreateObject("CDO.Configuration") ' iConf.Load -1 ' CDO Source Defaults ' Set Flds = iConf.Fields ' With Flds ' .Item("http://schemas.microsoft.com/cdo/configuration/sendusing") = 2 ' .Item("http://schemas.microsoft.com/cdo/configuration/smtpserver") = " ' .Item("http://schemas.microsoft.com/cdo/configuration/smtpserverport") = 25 ' .Update ' End With With iMsg Set .Configuration = iConf .To = ; " .CC = " .BCC = "" .From = """Excel"" " .Subject = "Important message" .TextBody = "AA has reached its stop loss" & vbNewLine & vbNewLine & _ "Please review this position immediately." .Send End With Set iMsg = Nothing Set iConf = Nothing End Sub Any thoughts? |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
That is my smtp according to outlook...I did read your site and I'm trying to
get around the constant message approval. We have outlook and I'm not sure exactly what year of windows. I thought I understood most everything on the site, but maybe not. "Ron de Bruin" wrote: Have you read all information on my site ?? http://www.rondebruin.nl/cdo.htm I see that you not use the commented lines and i see a strange name for the SMTP server -- Regards Ron de Bruin http://www.rondebruin.nl/tips.htm "Macro not running as intended" om wrote in message ... I'm getting an error when I am using this macro: Sub AA_CDO() Dim iMsg As Object Dim iConf As Object ' Dim Flds As Variant Set iMsg = CreateObject("CDO.Message") Set iConf = CreateObject("CDO.Configuration") ' iConf.Load -1 ' CDO Source Defaults ' Set Flds = iConf.Fields ' With Flds ' .Item("http://schemas.microsoft.com/cdo/configuration/sendusing") = 2 ' .Item("http://schemas.microsoft.com/cdo/configuration/smtpserver") = " ' .Item("http://schemas.microsoft.com/cdo/configuration/smtpserverport") = 25 ' .Update ' End With With iMsg Set .Configuration = iConf .To = ; " .CC = " .BCC = "" .From = """Excel"" " .Subject = "Important message" .TextBody = "AA has reached its stop loss" & vbNewLine & vbNewLine & _ "Please review this position immediately." .Send End With Set iMsg = Nothing Set iConf = Nothing End Sub Any thoughts? |
#4
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
By commented lines do you mean the additional lines you have listed? Or did
I not change something I needed to? "Ron de Bruin" wrote: Have you read all information on my site ?? http://www.rondebruin.nl/cdo.htm I see that you not use the commented lines and i see a strange name for the SMTP server -- Regards Ron de Bruin http://www.rondebruin.nl/tips.htm "Macro not running as intended" om wrote in message ... I'm getting an error when I am using this macro: Sub AA_CDO() Dim iMsg As Object Dim iConf As Object ' Dim Flds As Variant Set iMsg = CreateObject("CDO.Message") Set iConf = CreateObject("CDO.Configuration") ' iConf.Load -1 ' CDO Source Defaults ' Set Flds = iConf.Fields ' With Flds ' .Item("http://schemas.microsoft.com/cdo/configuration/sendusing") = 2 ' .Item("http://schemas.microsoft.com/cdo/configuration/smtpserver") = " ' .Item("http://schemas.microsoft.com/cdo/configuration/smtpserverport") = 25 ' .Update ' End With With iMsg Set .Configuration = iConf .To = ; " .CC = " .BCC = "" .From = """Excel"" " .Subject = "Important message" .TextBody = "AA has reached its stop loss" & vbNewLine & vbNewLine & _ "Please review this position immediately." .Send End With Set iMsg = Nothing Set iConf = Nothing End Sub Any thoughts? |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Using Macro how to create email link for the email addresses in aRange or Selection | Excel Worksheet Functions | |||
Email Macro help! | Excel Worksheet Functions | |||
Excel VBA macro to send email attachment from default email client | Excel Programming | |||
How do I create an email macro to auto fill the email? | Excel Discussion (Misc queries) | |||
Macro To Email XLS | Excel Discussion (Misc queries) |