Re: CDO.Message ????????
From: Egbert Nierop \(MVP for IIS\) (egbert_nierop_at_nospam.invalid)
Date: 10/17/04
- Next message: Egbert Nierop \(MVP for IIS\): "Re: Server.CreateObject("MSWC.Tools") fails in Windows 2003 server"
- Previous message: yabba: "Re: CDO.Message ????????"
- In reply to: yabba: "Re: CDO.Message ????????"
- Messages sorted by: [ date ] [ thread ]
Date: Sun, 17 Oct 2004 12:08:38 +0200
"yabba" <REMOVETHISyabbadoo_2004@hotmail.com> wrote in message
news:uP2tNx0sEHA.3884@TK2MSFTNGP10.phx.gbl...
> Thanks but that's not it... I am setting a number of cdo parameters
> besides
> the standard to, from, subject and etc. and I want to be sure the cdo
> object
> is refreshed/cleared after each send.
That's simple.
Just put the set oCDO = CreateObject("CDO.Message")
within the loop, so you have a new message-id each time you send mail.
>
> In article <uKEN3NvsEHA.2072@tk2msftngp13.phx.gbl>,
> myfirstnameatlane34dotcommercial says...
>>
>>Here's a method, where your "list" is an array.
>>
>>
>>Dim oCDO
>>Dim aAddresses(2)
>>aAddresses(0) = "email1@example.com"
>>aAddresses(1) = "email2@example.com"
>>aAddresses(2) = "email3@example.com"
>>
>>Set oCDO = CreateObject("CDO.Message")
>>oCDO.From = "sender@example.com"
>>oCDO.Subject = "Howdy!"
>>oCDO.TextBody = "Test message"
>>
>>For i = 0 To UBound(aAddresses)
>> oCDO.To = aAddresses(i)
>> oCDO.Send
>>Next
>>
>>Set oCDO = Nothing
>>
>>Ray at work
>>
>>
>>
>>"yabba" <REMOVETHISyabbadoo_2004@hotmail.com> wrote in message
>>news:eqZdfrnsEHA.1400@TK2MSFTNGP11.phx.gbl...
>>> using...
>>>
>>> set cdo = createObject("CDO.Message")
>>> cdo.To = "email@domain.com"
>>> cdo.From = "name <anotheremail@domain.com>"
>>> cdo.Subject = "Howdy!"
>>> other parameters etc...
>>>
>>> I want to do this with a list of addresses... I know I can...
>>>
>>> set cdo = nothing
>>> set cdo = createObject("CDO.Message")
>>>
>>> for each item on the list to be sure and renew the cdo but there must be
>>> a
>>> better way.
>>>
>>> I can't find any info on how to clear the cdo obj.
>>>
>>> cdo.new
>>> cdo.clear
>>> cdo.delete
>>>
>>> Nuttin works...
>>>
>>> any ideas???
>>>
>>>
>>
>>
>
- Next message: Egbert Nierop \(MVP for IIS\): "Re: Server.CreateObject("MSWC.Tools") fails in Windows 2003 server"
- Previous message: yabba: "Re: CDO.Message ????????"
- In reply to: yabba: "Re: CDO.Message ????????"
- Messages sorted by: [ date ] [ thread ]