pdfServMachine by Broadgun Software

OEM & SDKs for Developers

Please email if you wish to obtain a license to integrate pdfMachine into your application.  Also, checkout our pdfServMachine SDK.  It is the preferred way to integrate pdfMachine.

Registry Settings

Certain behaviour of pdfMachine can be controlled via Windows registry settings. This should only be done by people who are comfortable with editing the registry.

The registry key for versions prior to 7.4 :

HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Print\Monitors\PDF Port Monitor\Ports\PDFPORT1:

In versions 7.4 and up, the registry settings are now stored under the key:

HKEY_CURRENT_USER\Software\pdfMachine\BroadGun pdfMachine

Registry Value  Name

Registry Type

Description

SaveFilenameAction

REG_DWORD Controls the filename of the resulting PDF file.
Valid Values  Description
1 Use the values for "DefaultSaveDir" and "DefaultSaveFilename" to generate a file name. This file will be overwritten without any prompting.
2 Use the document title for the filename. The file will be saved in the "DefaultSaveDir" directory. The document title is obtained from the pDocName member of the DOC_INFO_1 print job structure. 
This gives developers the opportunity to control the filename programmatically.
Note that is value may be automatically converted into a legal filename if it contains illegal filename characters. 
3 Same as '2' and also display the 'wait' dialog box with the gear animation.  
4 Generate a random filename in the "DefaultSaveDir"..  

 

DefaultSaveDir

REG_SZ The directory that is used to place the file when "SaveFilenameAction" is equal to 1 or 4.

DefaultSaveFilename

REG_SZ The default filename that is used when "SaveFilenameAction" is equal to 1.

NextAction

REG_DWORD Controls what happens after the PDF file has been generated.
Valid Values Action
1 Do nothing. No next action takes place.
2 Launch default PDF file viewer. 
3 Execute the command line that is defined by the registry value "ExecCmdLine".
4 Send email
5 Display "save as" dialog

 

 

ExecCmdLine

REG_SZ When "NextAction" is equal to 3, this is the command that is executed. It may contain a string such as "%s" which will be substituted with the full path of the generated PDF file.

e.g. ExecCmdLine = c:\winnt\notepad.exe "%s" 

This would launch the notepad.exe program upon completion of file generation. The notepad program would open the PDF file.

EmailOneShot

REG_DWORD If set and not zero, an email will be sent, regardless of other settings. The value is then set to zero after use. This is useful for an application that wants to send an email but not upset any other settings. This feature was introduced in version 8.9.

SaveFileOneShot

REG_SZ If set, it contains the full path and name of the PDF that will be generated. No user interface will be displayed.  This is useful for an application that wants to save a PDF file but not  upset any other settings. This feature was introduced in version 8.9.

EmailTo

REG_SZ If set provide default values for the default mail client when it is launched.

If the first character is an '@' then the rest of the text is taken to be a filename and the text is read from the file.

e.g if the "Email Body" value was "@c:\body.txt" then the file c:\body.txt would be read in and this would be placed in the body of the email.

For the TO, CC, BCC address fields, several addresses may appear if the addresses are comma or white space separated. Some email applications require the "SMTP:" prefix on mail addresses to send SMTP style mail.

 

EmailCC

REG_SZ When an email is to be sent, this value is used.

EmailBCC

REG_SZ When an email is to be sent, this value is used.

EmailSubject

REG_SZ When an email is to be sent, this value is used.

EmailBody

REG_SZ When an email is to be sent, this value is used.

UserConfirmAttachmentName

REG_DWORD If set to 1, then the user is prompted for the attachment name prior to sending an email.

AutomatedMapiSend

REG_DWORD If set to 1 and a EmailTo entry is present, then the email is sent automatically, without user intervention. .

StationeryEnableStationeryAllPages

REG_DWORD If set to 1, the file pointed to by "stationeryPathStationeryAllPages" is used as a stationery file for every page.

StationeryEnableStationeryFirstPage

REG_DWORD If set to 1, the file pointed to by "stationeryPathStationeryFirstPage" is used as a stationery file for the first page.

StationeryOnTopStationeryAllPages

REG_DWORD If set to 1, stationery is drawn last.

StationeryOnTopStationeryFirstPage

REG_DWORD If set to 1, stationery on first page is drawn last.

StationeryPathStationeryAllPages

REG_SZ The fullpath of the PDF file used for stationery.

StationeryPathStationeryFirstPage

REG_SZ The fullpath of the PDF file used for stationery on the first page.

sd_enabled

REG_DWORD If set to 1, security is enabled.

sd_keyLen

REG_DWORD set to either 5 for 40 bit encryption, or 16 for 128 bit encryption.

Calling pdfMachine from an application

The easiest way to generate a PDF file from an application is to first set either registry entries  EmailOneShot or SaveFileOneShot . Then print your document to the "Broadgun pdfMachine" printer.


 

Copyright © 2003 BroadGun Software Pty Ltd.  All rights reserved.