
Set and Email's To and Subject Fields
hi,
how do i programatically set the TO and SUBJECT fields of a Word email. I
am using the contents of an RTF created from an access report as the
contents of the email. thanks in advance
This is what i have so far:
strAttachmentName = "c:\temp\Wash-" & Format(Date, "mmddyy") & ".txt"
'output the report to a text file
DoCmd.OutputTo acOutputReport, strDocName, acFormatRTF,
strAttachmentName
Dim app As New Word.Application
Dim doc As Word.Document
app.Documents.Open strAttachmentName
app.Options.SendMailAttach = False
Set doc = app.ActiveDocument
'I NEED TO SET THE TO AND SUBJECT LINES HERE
app.ActiveDocument.SendMail
doc.Close
Set doc = Nothing
app.Quit
Set app = Nothing