But do you have code to email it?
Here's a sample if you don't...
sub createOutlookMailItem
Dim objOutlook As Outlook.Application
Dim newMail As MailItem
Set objOutlook = CreateObject("Outlook.application")
Set newMail = objOutlook.CreateItem(olMailItem)
newMail.To = "(e-mail address removed)"
newMail.Body = "The Office ribbon sucks like Dvorak"
Set newMailAttachments = newMail.Attachments
'If you're pulling records from a file, you'd start the loop here
changing the next
'line to file1 = rs("fieldName") or whichever way you prefer to pull the
value from
'the recordset you're working with, this code was done as a
proof-of-concept,
'so I used the file1 variable just to make the next line easier to read
it can
'be eliminated if needed
'I would definately check to see if the file exists first using the
FileExists property
'of the File System Object
'Set fs = CreateObject("Scripting.FileSystemObject")
'fs.FileExists(fileName)
'If FileExists fails, you could then present the CommonDialog to give
the users
'the option of searching for the file themselves (see mvps.org for that
aspect of
'it)
'change rptConfirmation.snp to the PDF's file name
file1 = strTargetFolder & "\rptConfirmation.snp"
newMailAttachments.Add file1, olByValue, 1
'end the loop here
newMail.Subject = "Documents Confirmation"
newMail.OriginatorDeliveryReportRequested = True
newMail.ReadReceiptRequested = True
newMail.Display
Set newMailAttachments = Nothing
Set newMail = Nothing
Set objOutlook = Nothing
end sub
You may also want to check out the .SaveSentMessageFolder property as it
would allow you to have the sent messages saved in a specific folder - either
at the user level or in a public folder.
http://msdn.microsoft.com/en-us/library/aa171932(office.11).aspx