ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Printing to PDF using VBA (https://www.excelbanter.com/excel-programming/300081-printing-pdf-using-vba.html)

carlsondmc

Printing to PDF using VBA
 
I am attemptiong to print to PDF as I am running through a alrge macr
set. My problem is getting the print to complete "without" having t
intervene and press save on the pop-up for printing.

Does anyone have any advice?

Thanks,
DM

--
Message posted from http://www.ExcelForum.com


Greg Evensen

Printing to PDF using VBA
 
Hi,
Virtual Port Monitor will redirect printer output
to a file by intercepting the data at the port level.
The file is named automatically according to the title
as viewed in the printer queue, or with a time stamp,
along with the options of including the username, computername,
title, or portname, in the resulting filename.

Our post-print application feature can be used to launch
Ghostscript to make the PDF. Ghostscript is the program
used by some "free" PDF writers using the
"prompt for filename ad" technique, except they hide
the modified 10 Mb Ghostscript distribution in a private
subdirectory to cloak the fact that they are using it to do
all the work of actually making the PDF.

I would like to add that the unregistered version of our
software displays a registration reminder, but once
registered, it goes away.

You can read more at http://www.alphatronics.com/AVPMon.html
where you can freely download the installer.

You can download Ghostscript from http://www.ghostscript.com
Ghostscript is free to use.

Greg

carlsondmc wrote in message ...
I am attemptiong to print to PDF as I am running through a alrge macro
set. My problem is getting the print to complete "without" having to
intervene and press save on the pop-up for printing.

Does anyone have any advice?

Thanks,
DMC


---
Message posted from http://www.ExcelForum.com/


gitcypher[_5_]

Printing to PDF using VBA
 
Do you have Acrobat distiller?

I had done this on a large printing macro a few months back. Usin
distiller, I printed each piece of the printjob 'to-file' with a .p
extension. As each piece printed, the code added a line of text to
script file (the path of the .ps files). I then called the distille
program to process the script, distilling each .ps file listed.

ActiveSheet.PrintOut , PrintToFile:=True, PrToFileName:="filename"
".ps"
That was how each .ps file was created. This gets rid of the prompt fo
where to save the file. In that code, the "filename" had to be the ful
path.

There's a lot more code involved in finally printing to PDF. Let m
know if this route is the one you'd like to take. I'll give you as muc
info as you need.

- Gitcyphe

--
Message posted from http://www.ExcelForum.com



All times are GMT +1. The time now is 12:13 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com