Access 2010 PDF and Email a Report Using VBA Code
Can anyone tell me the VBA code that will let me PDF and email an indiviual report based on a given unique ID. I am happy for the user to add the email address, subject and message body and for them to click send
Thank you for taking the time to report an issue.
What's wrong... Please write below.
I know that I can use SendObject to send a Snapshot View of a report. But who is at the other end to read it? The CIA could use snapshot format to send secret documents and no one would be able to break the code.
I need to send things as pdf's.
Again, I need to send a pdf from a MS Access program directly to an email attachment.
At the moment the client uses the button on the Print Preview ribbon (Access 2010) to convert the report to a PDF file. Client is asking if it is possible to automatically select the "Standard Publishing" option as it seems to default to "Minimum Size" each time.
If I use VBA to open report as hidden, create email object and attach it as PDF does it automatically get converted to the highest quality
I can currently send a report as an attachment in an Outlook Email by using the "DoCmd.SendObject acSendReport" code.
That works nicely for me because it attaches the report I specify but has the limitation that I cannot attach any other objects.
I therefore came across the following code which allows me to add multiple attachments to an Outlook email message:
The problem with the above is that I cannot figure out how to attach a report of my choice. I don't know if there is a way to tell access to open a report and attach it as a PDF (in the above code).
Worst comes to worst, I'll try to figure out a way to save the report as a PDF (to the local filesystem) and then attach that as one of the attachments.
I can do this via VBA in word but do not know the code well enough in Access to perform the same job.
My pdfs are located in a folder on the c: drive
All I want to do is open them and display them on the screen, I would then like to email them as an attachment
For example, when I open the service report for customer Johnson, I would like when I export the report (via email or save as pdf) that the report name be Johnson Service Report, rather than Service Report. This name would also change when I open the service report for cusotmer Wilcox, the report name would then be Wilcox Service Report. Is this possible?
This way when I save the pdf to the digital file I do not have to rename it, as well as if I am sending the report via email the specific customer will be noted in the report name without having to change it manually.
For some background on what I am trying to accomplish here. I have a table that contains the PersonnelName, email, cc, subject respectively and are all text fields. The code calls a recordset to "lookup" the respective fields and produce an email with the report attached. I am not so worried about saving the report as attaching it to the email to be sent out as this is done daily. Oh I should probably mention this is all done by clicking a command button. So how would I go about producing the pdf for attachment?
I really need someone to help me with some code that will email the staff using Outlook 2010. I am not a expert on the code side of things.
I require the code assigned to the 'email button' and it will generate a email. Their email address will come from the Access database and in the body of the email there will job status, who it is assigned to etc. The email will then go to the persons email address.
I have attached a old copy of the database, I have saved it in 2000/03 incase people cant open it.