G
Guest
I want to send separate emails to addresses in a table with corresponding
reports.
Table:
Office Email Report1 Report2
Cal (e-mail address removed) abc.xls hij.doc
Edm (e-mail address removed) asd.xls iop.doc
This is what I have so far.
Sub TestSendMailItem_Calgary2()
Dim email As String
SendMailItem _
vntTo:=DAO_Email_To(email), _
vntSubject:="My Subject Heading", _
vntBody:="This is the body text of the email and " & _
"I need more space", _
vntCC:="", _
vntAttachment1:="c:\Jessica\Sent\Calgary.xls"
End Sub
Function DAO_Email_To()
Dim rs As DAO.Recordset
Dim email As String
Set rs = CurrentDb.OpenRecordset("Select To From [00 Email Information]
Where DMSO = 'Calgary'")
email = rs.Fields(0).Value
HELP PLEASE!
reports.
Table:
Office Email Report1 Report2
Cal (e-mail address removed) abc.xls hij.doc
Edm (e-mail address removed) asd.xls iop.doc
This is what I have so far.
Sub TestSendMailItem_Calgary2()
Dim email As String
SendMailItem _
vntTo:=DAO_Email_To(email), _
vntSubject:="My Subject Heading", _
vntBody:="This is the body text of the email and " & _
"I need more space", _
vntCC:="", _
vntAttachment1:="c:\Jessica\Sent\Calgary.xls"
End Sub
Function DAO_Email_To()
Dim rs As DAO.Recordset
Dim email As String
Set rs = CurrentDb.OpenRecordset("Select To From [00 Email Information]
Where DMSO = 'Calgary'")
email = rs.Fields(0).Value
HELP PLEASE!