save as pdf using vba

T

tricky300

Hi,

Thanks to anyone that can help.

I have downloaded and installed Microsoft's useful 'extra' to save as pdf
within Access 2007. It works a treat but now I want to automate the SaveAs
procedure on a report using vba but have been unable to find out if this is
possible.

Does anyone out there know how to do it?
 
A

Allen Browne

tricky300 said:
I have downloaded and installed Microsoft's useful 'extra' to save as
pdf within Access 2007. It works a treat but now I want to automate the
Saveas procedure on a report using vba but have been unable to find
out if this is possible.

This kind of thing should do it:
strDoc = "Report1"
strFile = "C:\SomeFolder\SomeFile.pdf"
DoCmd.OutputTo acOutputReport, strDoc, acFormatPDF, strFile, True
 
T

tricky300

Thanks Allen, having done a little experiment, I am sure that has pointed me
in a direction that will lead to a solution.

Tricky300
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top