C
corquando
Greetings, geniuses.
I have a standard CDO send sub that works just dandy, except for on
small detail.
For each email there will be a variable amount of attachments
anywhere from 1 to maybe 15 tops.
In the .With statement, I have this (all required statements beforehan
are present. I'm just omitting them here for space's sake.):
Code
-------------------
'looped for each email sent
With iMsg
Set .Configuration = iConf
.To = EML 'email address from database
.CC = ""
.BCC = ""
.From = "(e-mail address removed)"
.Subject = Subj 'defined in the db
.TextBody = strbody 'defined in the db
.AddAttachment (Atch1) 'AHA!! Here's the rub!!
.Send
End With
[\code]
How may I:
a) Loop around the .AddAttachment statement to add the required attachments, or
b) define a variable that would contain the necessary attachment values (Atch1), and have the statement needed only once, and
c) which is best or does it matter?
I've seen solutions for non-CDO programs and earlier OL versions but I'm wary since what I'm doing is different, and spending 2 or 3 hours trying to force something that won't work anyway is demoralizing.
Please ask for whatever additional and needed items I have mindlessly omitted, and thanks in advance!!
I have a standard CDO send sub that works just dandy, except for on
small detail.
For each email there will be a variable amount of attachments
anywhere from 1 to maybe 15 tops.
In the .With statement, I have this (all required statements beforehan
are present. I'm just omitting them here for space's sake.):
Code
-------------------
'looped for each email sent
With iMsg
Set .Configuration = iConf
.To = EML 'email address from database
.CC = ""
.BCC = ""
.From = "(e-mail address removed)"
.Subject = Subj 'defined in the db
.TextBody = strbody 'defined in the db
.AddAttachment (Atch1) 'AHA!! Here's the rub!!
.Send
End With
[\code]
How may I:
a) Loop around the .AddAttachment statement to add the required attachments, or
b) define a variable that would contain the necessary attachment values (Atch1), and have the statement needed only once, and
c) which is best or does it matter?
I've seen solutions for non-CDO programs and earlier OL versions but I'm wary since what I'm doing is different, and spending 2 or 3 hours trying to force something that won't work anyway is demoralizing.
Please ask for whatever additional and needed items I have mindlessly omitted, and thanks in advance!!