Append to PDF file using the OutputTo command

  • Thread starter Thread starter Rolf
  • Start date Start date
R

Rolf

I am using the DoCmd.OutputTo command in Access 2007 to output reports in PDF
format. is it possible to make this command append to an already existing PDF
file?

Many thanks

Rolf
 
Did you ever find a solution for this issue? I need to figure out how to do this as well...



Rol wrote:

Append to PDF file using the OutputTo command
14-Apr-08

I am using the DoCmd.OutputTo command in Access 2007 to output reports in PD
format. is it possible to make this command append to an already existing PD
file

Many thank

Rolf

Previous Posts In This Thread:

Append to PDF file using the OutputTo command
I am using the DoCmd.OutputTo command in Access 2007 to output reports in PD
format. is it possible to make this command append to an already existing PD
file

Many thank

Rolf


Submitted via EggHeadCafe - Software Developer Portal of Choice
Add Windows GridView control in WPF dynamically in C#.
http://www.eggheadcafe.com/tutorial...1-bf33de76bd69/add-windows-gridview-cont.aspx
 
all,
below is code i use, hope it helps. i have the "Acrobat Adobe 8.0 Type
library" reference. i figure it should work in earlier versions but doubt
you can reference the library if you just have PDF viewer. the save file can
be the same as the orginal, i have also looped this type of code.

Function PDF_Combine_Final()
Dim AcroExchApp As Acrobat.CAcroApp
Dim AcroExchPDDoc As Acrobat.CAcroPDDoc
Dim AcroExchInsertPDDoc As Acrobat.CAcroPDDoc
Dim strFileName As String, strPath As String
Dim iNumberOfPagesToInsert As Integer
Dim iLastPage As Integer

Set AcroExchApp = CreateObject("AcroExch.App")
Set AcroExchPDDoc = CreateObject("AcroExch.PDDoc")

strFileName = "C:\OriginalFile.pdf"
AcroExchPDDoc.Open (strFileName)


iLastPage = AcroExchPDDoc.GetNumPages - 1
Set AcroExchInsertPDDoc = CreateObject("AcroExch.PDDoc")

AcroExchInsertPDDoc.Open ("C:\FileToInsert.pdf")
iNumberOfPagesToInsert = AcroExchInsertPDDoc.GetNumPages

AcroExchPDDoc.InsertPages iLastPage, AcroExchInsertPDDoc, 0,
iNumberOfPagesToInsert, 0
AcroExchInsertPDDoc.Close



PDF_Combine_Final_Exit:
AcroExchPDDoc.Save 1, "C:\NewFile.pdf"

AcroExchApp.Exit

Exit Function



End Function
 
JD said:
I am using the DoCmd.OutputTo command in Access 2007 to output reports in PDF
format. is it possible to make this command append to an already existing PDF
file?
Is there any way, from within Access, to concatenate several PDF
reports?

Install the open source software PDFCreator. (Watch out for the
*rsehole $$$ software with the same name.)
http://sourceforge.net/projects/pdfcreator/ Take a look at the VB
Script options in the C:\Program Files\PDFCreator\Scripts folder.
Figure out which one you need. With a bit of work you can convert the
VBScript code to VBA code.

As does Lebans solution although it's buried deep in the code. Given
that A2010 no longer supports snapshot format files which Lebans
solution creates first then I'd suggest using the above solution or
the others in this thread.

A2000ReportToPDF is an Access 2000 database containing a function to
convert Reports and Snapshot files to PDF documents. No PDF Printer
driver is required. Free.http://www.lebans.com/reporttopdf.htm

Tony
--
Tony Toews, Microsoft Access MVP
Tony's Main MS Access pages - http://www.granite.ab.ca/accsmstr.htm
Tony's Microsoft Access Blog - http://msmvps.com/blogs/access/
For a convenient utility to keep your users FEs and other files
updated see http://www.autofeupdater.com/
Granite Fleet Manager http://www.granitefleet.com/
 
Install the open source software PDFCreator. (Watch out for the
*rsehole $$$ software with the same name.)
http://sourceforge.net/projects/pdfcreator/ Take a look at the VB
Script options in the C:\Program Files\PDFCreator\Scripts folder.
Figure out which one you need. With a bit of work you can convert
the VBScript code to VBA code.

Er, there are native VBA examples for Access, Excel and Word.
 
Back
Top