Print-to-file in Adobe 6 gives "do not send fonts to Distiller" error

  I am trying to print Excel to Adobe 6 using VB.   The code is supposed to print to file with this line:
ActiveSheet.PrintOut , printtofile:=True
This line does not run but gets a message from adobe PDF:  
"When you create a Postscript file you have to send the host fonts. Please go to printer properties, "Adobe PDF settings" page and turn OFF the option "do not send fonts to Distiller""

  BUT - despite this message Adobe 6 doesn’t have "do not send fonts to Distiller". It does have " do not send fonts to Adobe PDF".   I have turned this off ... But it makes no difference.

Can someone explain how I can get print-to-file in Adobe 6 from VB

Thank you for your help

Stephen Kinsella

Who is Participating?
Karl Heinz KremerConnect With a Mentor Commented:
When you do a print to file (either withthe Adobe PDF printer, or the printer that you installed with the Distiller PPD) you will create a PostScript file, and not a PDF file. You need to call distiller from your program to convert this to PDF.
Programatically creating PDF by printing to the Adobe PDF printer requires this two step approach because you otherwise don't have any control over the output filename. You first write out a PostScript file with a filename that you specify in your program, then you start Distiller - using the Distiller API from the Acrobat SDK - to convert this Postscript file to PDF. As the last step, you delete the PostScript file.

Try to rename the file you've generated to a .ps extension and then double-click on it. Does Distiller start and create a PDF file?
Karl Heinz KremerCommented:
You are right, the setting is named "Do not send fonts to Adobe PDF". Adobe renamed the "Distiller" printer to "Adobe PDF" with Acrobat 6, and they may have missed this one string.

You need to uncheck this setting, so that the fonts are included in the PostScript file. Try to do a "Print to File" from an interactive application (e.g. Excel) and set this to on and off and see for yourself that it makes a difference. The problem is that you need to do this without the user interface, and I don't think that this is possible.

You can however change the defaults for the "Adobe PDF" printer, so that it always sends the fonts. Or, you can create a second instance of the Adobe PDF printer that you only use for saving PostScript files (you don't even need the port monitor: Just get the Adobe PostScript driver, and install a printer that points to the Distiller PPD.
Karl Heinz KremerCommented:
You can find the Disilller PPD here: C:\Program Files\Adobe\Acrobat 6.0\Distillr\Xtras
Easily Design & Build Your Next Website

Squarespace’s all-in-one platform gives you everything you need to express yourself creatively online, whether it is with a domain, website, or online store. Get started with your free trial today, and when ready, take 10% off your first purchase with offer code 'EXPERTS'.

Stephen-KinsellaAuthor Commented:
thankyou khk
I have tried your first suggeston - print to file from Excel
1) with the "do not send fonts" unchecked - print to file creates a file with no suffix. If I rename it *.ps and click, Distiller pops up and it is recreated as a pdf file, which looks OK. It also makes a pdf log.

2) with "do not send fonts" checked  - print to file does exactly the same as 1).

So it makes no difference that I can see. What does this tell you?  Am I looking at the wrong thing?

On your second suggestion, how would a second printer be any different from the first??  Do you still suggest the PPD?  If so, could you give me a guide as to how I carry out your suggestion to install  a printer that points to the PPD - I am not a programmer - I just make my own VBA applications for Excel, which I use all the time.

Thanks v much for your help

Karl Heinz KremerCommented:
Did you change this setting in the Control Panel/printer configuration? If not, do the following:

Open the Control Panel and select the "Printers and Faxes" option. Select the Adobe PDF printer and do a right mouse click and select "Properties". Click on the "Printing Preferences" button on the "General" tab. This will give you access to the "Do not send fonts..." option as a default setting. When you disable it here, you should never have to set it in your print dialog, and all print jobs that are automatically created (e.g. via your VBA application), will also use this setting.

You should probably exit all applications that you want to print from after you make this change.

To not have to change your standard Adobe PDF settings (which will also be active if you print to the Adobe PDF printer interactively), I suggested a second printer that uses the same PPD. If the first suggestion works for you, there is no need to create the second printer, if it does not work, I can give you step by step instructions.

Stephen-KinsellaAuthor Commented:
Yes, I unchecked the box in Adobe PDF printer properties via control panel/printers/adobe pdf.  Whether the box is checked or unchecked,'print to file' direct from the Excel print menu to Adobe PDF creates a PS file, so far as I can tell.

(I gather from your answer to another query in EE that it is the attempted creation of a PS file that gives the error message, if I understand correctly.)

I don't know what PPD is.  If this is the solution I would be very grateful for step by step instructions


Stephen-KinsellaAuthor Commented:
I hadnt tried exiting the application between turning on and off the adobe printer properties box - I have now and  I have to amend the above. Yes there is now the difference when printing to file direct from notepad or excel, it only gives the error message when the box is checked. But when printing to file from VB it still gives the error message whether box is checked or not, even if I close Excel and reload after I change the tick box.  

Karl Heinz KremerCommented:
A PPD file is a PostScript Printer Description file, which - as the name implies - describes the features that a PostScript printer supports. Download the PostScript driver from Adobe's web site:

Start the installer.
On the "Printer Connection Type" screen select the "is directly connected" option.
On the "Local Port Selection" screen select the "File" port.
On the "Select Printer Model" screen click on the "Browse" button. Then browse to this directory: "C:\Program Files\Adobe\Acrobat 6.0\Distillr\Xtras" and select the "Adobe PDF" printer. Click on "OK"
Configure the printer as "Not shared"
Give the new printer a name (can be anything, but you should probably use something that describes the printer - e.g. "Distiller PPD"). Don't make this your default printer, and don't print a test page at this time.

Now try to print programatically to this printer.
Stephen-KinsellaAuthor Commented:
I have followed this and found that the printtofile line now is executed from Excel VB. It creates a .pdf file. However when I try to open this file Adobe says "could not open *.pdf because it is not a supported file type, etc.   I am trying to print a small range from an Excel sheet.

Can you tell me what  I do now?

Many thanks
Stephen-KinsellaAuthor Commented:
Thank you very much khkremer, you have given me what I needed.

I have added the following (which I  found on pdf planet) which turns the ps file programatically to a pdf file:

DistillerCall = "C:\Program Files\Adobe\Acrobat 6.0\Distillr\Acrodist.exe" & _
" /n /q /o" & PDFFileName & " " & PSFileName
'Call the Acrobat Distiller to distill the PS file. ReturnValue is zero
'if the application doesn't open correctly:
ReturnValue = Shell(DistillerCall, vbNormalFocus)
If ReturnValue = 0 Then MsgBox "Creation of " & PDFFileName & "failed."

I am now well on the way to automatic pdf printing of multiple excel sheets produced via VB in Excel.

Thanks again

Stephen Kinsella
Karl Heinz KremerCommented:
If you are satisfied with the solution, you should close this question. If you need information about how to do that, please review this page:
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.