SetPrint

In order to get the best quality output from FrameMaker, you should first create PDFs using Adobe PDF, then print the PDF. This results in better images and a more trouble-free workflow.

However, you might want your other Windows print jobs to go to your normal desktop or network printer. Unfortunately, when FrameMaker initializes, it simply sets its printer to the Windows default printer. So if you want to use a desktop printer for your other work, but use Adobe PDF for all your FrameMaker documents, you have to manually change the printer every time you start FrameMaker.

SetPrint changes that. It will automatically set your printer every time you start FrameMaker, and you can also call it as a client from FrameScript or FrameMaker plugins.

To install, create a new directory under the FrameMaker plugins directory and copy the file there. For example, if FrameMaker is installed in

C:\Program Files\Adobe\FrameMaker6.0\

then copy SetPrint.dll to a new directory named

C:\Program Files\Adobe\FrameMaker6.0\fminit\Plugins\SetPrint

When you restart FrameMaker, the plugin installs itself automatically.

Download SetPrint.dll .

It has been tested with versions of FrameMaker between 6.0 and 9.0 for Windows. It should continue to work with newer versions.

Using SetPrint on initialization

If you want SetPrint to run automatically whenever you start FrameMaker, create a small initialization file named SetPrint.ini. Store this file in the same directory as the DLL.

Edit the file using a text editor like Notepad, and enter a line similar to the following:

Printer=printer name

If you want to use the Adobe PDF printer instance from within FrameMaker, enter Adobe PDF in the file. This name has to match the name of your Windows printer exactly. Make sure there are no spaces either before or after the printer name.

When FrameMaker starts, SetPrint will read the file and set the FrameMaker printer to the name you specify, if it exists.

Calling SetPrint from FrameScript or another FrameMaker plugin

You can use either the CallClient command in FrameScript or the F_ApiCallClient function from a FrameMaker plugin to call SetPrint.

For FrameScript, use syntax similar to this:

CallClient FrameClient('SetPrint') Message(printer name) ReturnVal(retVar);

For a FrameMaker plugin, use syntax similar to this:

F_ApiCallClient( (StringT) "SetPrint", printer name );

Saving and restoring printer status

If you call SetPrint with a printer name of

/save

it will save the current printer status. You can then change the printer by calling SetPrint again. To restore to the original printer, call SetPrint with the printer name of

/restore

Return codes

SetPrint can return any of the following codes:

License

SetPrint is released under the terms of the GNU General Public License, version 2. Download source code, including the complete license: SetPrintSource.zip.

This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

Feedback

If you try it, please let us know how it works. That's a fair trade. You get a free FrameMaker utility, and we get your opinion about it. While you're at it, feel free to suggest ideas for other FrameMaker utilities.

We will never use your email address for any sort of mass mailing. In fact, unless you have a specific question or request a response, we may not reply at all. In any case, thank you for your feedback.