ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   CDO.Message (https://www.excelbanter.com/excel-discussion-misc-queries/137426-cdo-message.html)

Andrea

CDO.Message
 
Hi all,
I'm using this procedure in order to send mail:

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

With iMsg
Set .Configuration = iConf
.To = "
.CC = ""
.BCC = ""
.From = """Max"" "
.Subject = "Mail Subject"
.TextBody = "Text Example"
.AddAttachment "C:/Temp/" & WBname
.Send
End With

all works fine on my computer, but in office I receive this error message:

RUN TIME ERROR (80040220)
Configuraton Value "SendUsing" is invalid.

Please, can someone tell me what is the cause?

Thanks in advance
JFM



Ron de Bruin

CDO.Message
 
Read the information on my site Andrea
http://www.rondebruin.nl/cdo.htm


--

Regards Ron de Bruin
http://www.rondebruin.nl/tips.htm


"Andrea" wrote in message ...
Hi all,
I'm using this procedure in order to send mail:

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

With iMsg
Set .Configuration = iConf
.To = "
.CC = ""
.BCC = ""
.From = """Max"" "
.Subject = "Mail Subject"
.TextBody = "Text Example"
.AddAttachment "C:/Temp/" & WBname
.Send
End With

all works fine on my computer, but in office I receive this error message:

RUN TIME ERROR (80040220)
Configuraton Value "SendUsing" is invalid.

Please, can someone tell me what is the cause?

Thanks in advance
JFM



Ron de Bruin

CDO.Message
 
Read the information on my site Andrea
http://www.rondebruin.nl/cdo.htm

--

Regards Ron de Bruin
http://www.rondebruin.nl/tips.htm


"Andrea" wrote in message ...
Hi all,
I'm using this procedure in order to send mail:

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

With iMsg
Set .Configuration = iConf
.To = "
.CC = ""
.BCC = ""
.From = """Max"" "
.Subject = "Mail Subject"
.TextBody = "Text Example"
.AddAttachment "C:/Temp/" & WBname
.Send
End With

all works fine on my computer, but in office I receive this error message:

RUN TIME ERROR (80040220)
Configuraton Value "SendUsing" is invalid.

Please, can someone tell me what is the cause?

Thanks in advance
JFM




All times are GMT +1. The time now is 10:19 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com