Rabu, 17 November 2021

Re: [MSAccessProfessionals] DoCmd.SendObject method - Rename Attachment

Frank, 
Check out this from MVP Daniel Pineault 


Duane
Sent from my mobile

On Nov 17, 2021, at 6:34 PM, Frank C. D'Amato - KB2MXV <kb2mxv@gmail.com> wrote:


I'm using the following code to populate a email message and attach a report.

The attached report is the actual name of the report (In this case ROC Tolerance.pfd)

Is there a way that I can rename the report attached?

I do have a text field on my form [Text513] that I would like to rename the "ROC Tolerance.pdf" attachment to
 
DoCmd.SendObject acReport, "ROC Tolerance", acFormatPDF, _
  Forms![Customers]![email], , , "Report of Calibration", "Attached is Report of Calibration for the following device" & Chr(10) & Chr(10) & "Manufacturer: " & Forms![Customers]![Instruments].Form![Manufacturer] & Chr(10) & Chr(10) & "Model #: " & Forms![Customers]![Instruments].Form![Model] & Chr(10) & Chr(10) & "Serial #: " & Forms![Customers]![Instruments].Form![serial #] & Chr(10) & Chr(10) & "Date of Calibration: " & Forms![Customers]![Instruments]![Tests].Form![Date of Calibration] & Chr(10) & Chr(10) & "Thank You", True
 


Thanks
Frank D'Amato

Tidak ada komentar:

Posting Komentar