ToPDF (BCL easyPDF)
This converts any file type to PDF, the searchability status of the output PDF depends on the source document, for example, MS Office Input file.
This step uses a virtual printer to print files to a PDF file instead of a physical printer. Due to the printer and Microsoft office automation, there are a lot of technical and security limitations. Thus, we have introduced different methods of converting files to PDF so that our users can have a robust solution to their requirements.
We have provided a configuration file to allow users to switch between these various methods.
Overview of the Different Conversions Methods
Low-Code Solutions use three different methods to convert office files to PDF files, these methods are explained in the section below.
MS Office Native Conversion
This step uses the “Save as PDF” option in MS Office to save the PDF file directly. This requires Microsoft Office 2007 or newer. Microsoft Office 2007 requires the free “Save as PDF or XPS” add-in for Office 2007 to be installed. We recommend you use the 2010 and new versions.
If you are not interested in changing properties like Image Compression, Image Downsizing, Font embedding and you are ok with the default PDF/A output from your version of office, we recommend using this approach.
MS Office Direct Print
This method uses the BCL ‘easyPDF SDK x’ printer to print out PDF files directly from Microsoft Office. This is the recommended option for producing PDF/A files and PDF files with font embedding.
MS Office Extended Print
In this method, Office automation is used to create an intermediate XPS file, which is then printed with automatic hyperlink extraction. This approach has some technical differences to the first method that allows the users to use the software in a different way. This requires Microsoft Office 2007 or newer. Microsoft Office 2007 requires the free “Save as PDF or XPS” add-in for Office 2007 to be installed.
If you are performing conversions in server environments, for example, via IIS, Windows Services, Session 0 and ASP, this method does not require an interactive user to be logged on for server conversions to succeed, thus we recommend this setting for server environments.
Comparison of the features provided by the different methods
The table below shows you the features available in the different methods.
Property | Direct Print | Extended Print | Native Conversion |
---|---|---|---|
Bookmark depth | ✔ | ✔ | ✔ |
Convert Hyperlinks | ✔ | ✔ | ✔ |
Convert Bookmarks (Word) | ✔ | ✔ | ✔ |
IncludeDocumentMarkups (Track Changes Word) | ✔ | ✔ | ✔ |
Paper Orientation | ✔ | ✔ | ✔ |
Paper Size | ✔ | ✔ | ✔ |
Margin | ✔ | ✔ | ✔ |
PDFA1b | ✔ | ✔ | Depends on the version of Microsoft Office |
PDFX1a | ✔ | ✔ | Depends on the version of Microsoft Office |
PDFX3 | ✔ | ✔ | Depends on the version of Microsoft Office |
Image Compression | ✔ | ✔ | ✖ |
Image Downsizing | ✔ | ✔ | ✖ |
Font Embedding | ✔ | ✔ | ✖ |
Print All Sheets(Excel) | ✔ | ✔ | ✔ |
Include Document Properties | ✖ | ✔ | ✔ |
Fit to Page (Excel) | ✔ | ✔ | ✔ |
MSG Files | ✔ | ✖ | ✖ |
Frame Slides (PowerPoint) | ✔ | ✔ | ✔ |
Print Color Type (PowerPoint) | ✔ | ✔ | ✔ |
Output Type (PowerPoint) | ✔ | ✔ | ✔ |
Handout Order (PowerPoint) | ✔ | ✔ | ✔ |
Print Graphics (Pub) | ✔ | ✖ | ✖ |
In-depth Look at the Configuration file
The configuration file can be found in:
“<Autobahn DX Installation directory>\distribution\pj\bin\topdf.exe.config”
Below are the contents of the configuration file, to use a method for a file type, just write the extension in the value property of the conversion Method as shown below.
Do not write an extension in more than one method.
<!-- Extension Mapping --> <add key="AutoExtension" value="" /> <add key="AutoExtensionEx" value=".jpeg.jpg" /> <add key="AutoExtensionOpenNative" value="" /> <add key="AutoExtensionNative" value="" /> <add key="WordExtension" value="" /> <add key="WordExtensionEx" value=".docx.doc.rtf" /> <add key="ExcelExtension" value="" /> <add key="ExcelExtensionEx" value=".xls.xlsx" /> <add key="GenericExtension" value=".txt.dwg" /> <add key="PowerPointExtension" value="" /> <add key="PowerPointExtensionEx" value=".ppt.pptx" /> <add key="VisioExtension" value="" /> <add key="VisioExtensionEx" value=".vsd" /> <add key="IEExtension" value=".xml" /\> <add key="PublisherExtension" value="" /> <add key="PublisherExtensionEx" value=".pub.puz" /> <add key="IEExtendedExtension" value=".mht" /> <add key="HTMLExtension" value=".htm.html.eml" /> <add key="OutlookExtension" value=".msg" /> <add key="OpenOfficeExtension" value=".odt.swx.wpd.ods.sxc.odp.sxi.odg.sxd" /> <add key="ExcludedExtensions" value=".zip.exe.pps.ps.chm" /> <add key="PDFExtension" value=".pdf" />
Mappings Between Configuration File and the Conversion Methods
The table below maps the configuration file with the Conversion Methods discussed earlier.
The Configuration options ending with “Ex” work with the “NativeOfficePDF” config option to select a suitable conversion method.
| Configuration | Conversion Method | File Types | Comment | | –––––––––––––––––––––––––––– | —————– | ———————————————————— | –––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––– | — | | AutoExtension | Direct Print | All file types | This option works with any file extension that has an application that is compatible with the BCL printer | | AutoExtensionEx | Extended Print | All file types | This option works with any file extension that has an application that is compatible with the BCL printer | | AutoExtensionNative | Native Conversion | MS Office files | | | OpenOfficeExtension | Direct Print | Open Office files | This option works with all files that can be opened in Open Office. | | AutoExtensionOpenNative | Native Conversion | Open Office files | This option works with all files that can be opened in Open Office. | | WordExtension | Direct Print | .doc, .docx, .rtf… (All files that can be opened in MS Word) | | | WordExtensionEx NativeOfficePDF=true | Native Conversion | .doc, .docx, .rtf… (All files that can be opened in MS Word) | | | WordExtensionEx NativeOfficePDF=false | Extended Print | .doc, .docx, .rtf… (All files that can be opened in MS Word) | | | ExcelExtension | Direct Print | .xls, .csv, .xlsx… (All files that can be opened in Excel) | | | ExcelExtensionEx NativeOfficePDF=true | Native Conversion | .xls, .csv, .xlsx… (All files that can be opened in Excel) | | | ExcelExtensionEx NativeOfficePDF=false | Extended Print | .xls, .csv, .xlsx… (All files that can be opened in Excel) | | | PowerPointExtension | Direct Print | .ppt, .pptx (All Power Point files) | | | PowerPointExtensionEx NativeOfficePDF=true | Native Conversion | .ppt, .pptx (All Power Point files) | | | PowerPointExtensionEx NativeOfficePDF=false | Extended Print | .ppt, .pptx (All Power Point files) | | | VisioExtension | Direct Print | .vsd | | | VisioExtensionEx NativeOfficePDF=true | Native Conversion | .vsd | | | VisioExtensionEx NativeOfficePDF=false | Extended Print | .vsd | | | IEExtension | Direct Print | .html, .xml, .mht. All IE files. | | | IEExtendedExtension | Extended Print | .html, .xml, .mht. All IE files. | | | HTMLExtension | Direct Print | .htm, .html, eml | | | PublisherExtension | Direct Print | .pub, .puz | | | PublisherExtensionEx NativeOfficePDF=true | Native Conversion | .pub, .puz | | | PublisherExtensionEx NativeOfficePDF=false | Extended Print | .pub, .puz | | | OutlookExtension | Direct Print | .msg files | | | PDFExtension | | PDF files | We usually convert PDF attachments if you select the option | | | GenericExtension | Direct Print | .txt, .dwg | The GenericExtension print job is normally only used as a last resort, when a file type is totally unrecognized by the ToPDF component. This defaults to use Windows Notepad for output. | | ExcludedExtensions | | others | Skips all the extensions present here. |