Solved

Output Report to PDF for Preview

Posted on 2008-10-20
5
922 Views
Last Modified: 2013-11-28
I am using the following code within a Button on a report
    'DoCmd.OutputTo acOutputReport, , "PDF Format (*.pdf)", Me.Report.Name & " " & Format(Now(), "ddmmyyyy-hhnnss")
OR
    DoCmd.OutputTo acOutputReport, , acFormatPDF

These work fine and save the file as predetermined name or specified name but the file is saved and not displayed in Adove Reader / Writer

If I do File - Save As PDF or XPS the file is previewed, I can then comment / edit with Writer and email to a recipient which is what I want to do

I know I can email the file via SendObject As etc... But I like to comment on the PDF first, underline points bold etc.....

Anyone any Ideas - Thanks - Perhaps a way to do the File - Save As PDF / XPS would suffice
0
Comment
Question by:Wizard_IT
  • 3
  • 2
5 Comments
 
LVL 22

Accepted Solution

by:
Kelvin Sparks earned 500 total points
ID: 22756148
DoCmd.OutputTo acOutputReport, , acFormatPDF, ,True
should preview it when complete

Kelvin
0
 

Author Comment

by:Wizard_IT
ID: 22756169
It doesn't - I would expect it to
Access 2007 Latest SP - No Runtime - Access PDF / XPS Addins installed and working OK
0
 
LVL 22

Expert Comment

by:Kelvin Sparks
ID: 22756197
?? I'll have to check my 2007 setup, currently running PC in 2003 mode, so can't go there at present.
0
 
LVL 22

Expert Comment

by:Kelvin Sparks
ID: 22756282
OK

I've checked this on a 2007 machine and it did open the pdf in Acrobat Standard (not Reader).

Can you check the file associations for your pc to see what program is associated with pdf's.

In my case it is the Acrobat Standard - but that is for another reason on that machine.

I'm running Access 2007 SP1 over Win XP, Access PDF / XPS Addins installed

I did notice a slight delay in the file opening after the pdf write.

Kelvin
0
 

Author Comment

by:Wizard_IT
ID: 22756630
Great

Works fine - I was being a plonker

I tied it earlier hardcoding the filename but forgetting the extension .pdf - assumed it would append the PDF - It was simply that

Thanks and enjoy the points
0

Featured Post

Ransomware: The New Cyber Threat & How to Stop It

This infographic explains ransomware, type of malware that blocks access to your files or your systems and holds them hostage until a ransom is paid. It also examines the different types of ransomware and explains what you can do to thwart this sinister online threat.  

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article is a continuation or rather an extension from Cascading Combos (http://www.experts-exchange.com/A_5949.html) and builds on examples developed in detail there. It should be understandable alone, but I recommend reading the previous artic…
I see at least one EE question a week that pertains to using temporary tables in MS Access.  But surprisingly, I was unable to find a single article devoted solely to this topic. I don’t intend to describe all of the uses of temporary tables in t…
In Microsoft Access, learn how to “cascade” or have the displayed data of one combo control depend upon what’s entered in another. Base the dependent combo on a query for its row source: Add a reference to the first combo on the form as criteria i…
Using Microsoft Access, learn some simple rules for how to construct tables in a relational database. Split up all multi-value fields into single values: Split up fields that belong to other things into separate tables: Make sure that all record…

772 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question