+ Reply to Thread
Results 1 to 3 of 3

Thread: Pdf Report Writer?

  1. #1
    Registered User
    Join Date
    01-03-2012
    Location
    Taiwan
    MS-Off Ver
    Excel 2007
    Posts
    3

    Pdf Report Writer?

    Hi,

    I'm using Access 2007 and can use VBA to open a report, no problem.

    However, I need these reports to be printed as pdf files.


    At the moment:

    1) The pdf's filename is copied to the clipboard
    2) VBA opens the report in preview mode
    3) The user presses ctrl+P > Enter to print
    4) The user is prompted for the pdf filename, and presses ctrl+V to paste it


    Is there a way I can just create the pdf without any user interaction?

    Thanks,
    Andy
    Last edited by ambitw; 01-16-2012 at 04:20 AM.

  2. #2
    Registered User
    Join Date
    04-19-2010
    Location
    Ohio, USA
    MS-Off Ver
    Excel 2007
    Posts
    76

    Re: Pdf Report Writer?

    ambitw,

    From Access I use this daily to dump all my production reports to a shared drive.
    "rptHandout" - is the name of the report I created.
    acFormatPDF tells it to do a pdf
    and then the next arguement is where you want to put it.
    You can put this in line with any other automation you have.
    DoCmd.OutputTo acOutputReport, "rptHandout", acFormatPDF, "C:\myPath\myfile" & Format(Date, "mmddyy") & ".pdf"
    So today I would have a report at C:\myPath\myfile011012.pdf

  3. #3
    Registered User
    Join Date
    01-03-2012
    Location
    Taiwan
    MS-Off Ver
    Excel 2007
    Posts
    3

    Re: Pdf Report Writer?

    Thanks Bmoe!

    That was perfect!

    Andy

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.2.0