Monday, October 15, 2007 11:12 AM
I am using Access 2007 with the add-in to export to PDF which generally works OK. I use the command below to generate the PDF
DoCmd.OutputTo acOutputReport, strReportName, acFormatPDF, strPath, , , , acExportQualityPrint
Works fine for portrait mode and works fine on our dev server
The issue is that for landscape reports on our test server the PDF is often (but not always) truncated (both to the right hand side of the page and the bottom) .
Any ideas ? As far as I know its the same version of Access and the same export to PDF add-in ?
Thursday, October 18, 2007 12:56 AM
I'm using an older version of Access, without the pdf output add-in that you refer to. We currently use a third party pdf printer driver, but in the past we have used the older "snapshot" output. Because of the difference in versions, I don't know if this will have any bearing on your problem, but we had a similar issue when using the snapshot output and perhaps our work-around will also work for you.
Regardless of whether we printed or used the output command, Access still appeared to use the page margins as set in Page Setup. I think it uses the greater of the margins set in the report/form and the margins set in Page Setup. If you find that your output is fine some of the time, and not others, it may be because the default page margins differ either from PC to PC or from user to user. We had few users and few PCs, so we set them all to the same settings manually, but you may be able to add code to your script to set the page margins (the .Left, .Width, .Top and .Height properties apply to a form or report but I don't think they actually override the default page margins).
Furthermore, we found that some of the output formats seemed to add their own margin in addition to the default margin. This resulted in an overwide top and left margin, which could result in truncation of the right and bottom of the output. Our solution was to set the Access page setup top and left margins to zero, and right and bottom margins to the total of the margins we wanted. Unfortunately the resulting output was not always centred on the page, but at least it didn't get truncated.
Thursday, October 18, 2007 8:36 AM
Hey Thanks for the reply.
I actually sorted it by the following:
1) Uninstall the PDF export Add-in
2) Uninstall Office 2007
3) Reboot (probably this did the trick!)
4) Reinstall Office 2007
5) Reinstall the PDF export Add-in
A bit brutal but it seemed to do the trick !