Sending email (recipients)
- From: "B" <no_spam@xxxxxxxxxxx>
- Date: Thu, 29 Jun 2006 18:46:27 -0400
Follow-up to my original post.
Is it possible for the "objEmail.To" to lookup the values from a sqlserver
table?
At the moment, I type the email address separated by a semi-colon.
TIA~
Set objEmail = CreateObject("CDO.Message")
objEmail.From = "send@xxxxxxxx"
objEmail.To = "receive@xxxxxxxx"
objEmail.Subject = "TEST SUBJECT"
objEmail.AddAttachment "\\server\test.csv"
objEmail.Configuration.Fields.Item("http://schemas.microsoft.com/cdo/configu
ration/sendusing") = 2
objEmail.Configuration.Fields.Item("http://schemas.microsoft.com/cdo/configu
ration/smtpserver") = "SERVER_NAME"
objEmail.Configuration.Fields.Item("http://schemas.microsoft.com/cdo/configu
ration/smtpauthenticate") = 1
objEmail.Configuration.Fields.Item("http://schemas.microsoft.com/cdo/configu
ration/sendusername") = "username"
objEmail.Configuration.Fields.Item("http://schemas.microsoft.com/cdo/configu
ration/sendpassword") = "userpwd"
objEmail.Configuration.Fields.Item("http://schemas.microsoft.com/cdo/configu
ration/smtpserverport") = 25
objEmail.Configuration.Fields.Update
objEmail.Send
set objEmail = nothing
.
- Follow-Ups:
- Re: Sending email (recipients)
- From: Dan Guzman
- Re: Sending email (recipients)
- Prev by Date: SQL Server 2005 Express
- Next by Date: Re: left() and right() function in MS SQL vs MS ACCESS
- Previous by thread: SQL Server 2005 Express
- Next by thread: Re: Sending email (recipients)
- Index(es):
Relevant Pages
|