BCL Drake® 7.0 is an advanced document conversion tool that automatically converts PDF documents to editable Rich Text Format (RTF) documents. The software automatically zones the text, tables and graphics within PDF files, and preserves the original look and feel of the document when creating RTF output. The RTF output will look the same as the original document because the information is accurately preserved using Microsoft Word® drawing features to maintain the original page structure.
BCL DrakeŽ 7.0 COM requires the following hardware and software:
Each of the BCL COM Objects ship with a standard InstallShield Wizard to unpack the files and register the libraries. By default, the necessary dll and sample source files are installed here:
c:\Program Files\BCL Technologies\*
Use regsvr32.exe to register DrakeCom.dll.
note: The dll is automatically registered during setup.
All of BCL's COM Objects can be accessed from a variety of programming environments. This section shows the basics of COM Objects and how to access them. If you are already familiar with using COM Objects, skip to Sample Code to get started right away.
Viewing Component ProgID, Methods & Properties
COM Objects in Visual Basic
COM Objects in Visual C++
BCL Drake COM® 7.0 allows you to access the PDF -> RTF conversion functionalities programmatically from several programming environments. The COM interface can currently be accessed from C, C++, and Visual Basic. By default, the sample code is installed in the default Drake COM directory. The sample code can also be found in SampleCode.zip.
Default File Location C:\Program Files\BCL Technologies\BCL Drake 7.0 COM\VB Sample\ Files to Edit DrakeCOMVBClient.frm
Default File Location C:\Program Files\BCL Technologies\BCL Drake 7.0 COM\VC Sample\ Files to Edit COMClientDlg.cpp
The COM ID for Drake 7.0 COM is "DrakeCom.Drake". Information on instantiating Drake can be found here.
short GetNumPages(string strFileName) Retrieve the number of pages in the PDF file short SetOptionsXML(string strOptions) Set conversion settings specified by strOptions string GetOptionsXML() Returns an option string listing all of the options not currently set to 0 or FALSE. void ResetOptions() Reset conversion settings back to their default values long Convert(string strInFile, string strOutFile, variant strErrMsg) Starts the actual conversion void CancelConvert() Cancels the current conversion.
void OnProgress(long progress, long limit) Event raised by the COM object to signal the current conversion progress.
Command String (XML Document)
note: The command string is an XML document used to set the options. An example can be found here.
AdjustFontNames If you select this option, Drake will use the fonts on your machine, once the extraction is done, to ensure the accuracy of the original document layout. AdjustSpacing If you select this option, Drake will adjust the spacing according to PDF spacing. ConversionMethod Select between Preserve layout using spaces and tabs, Exact placement using textboxes, or Text flow output. DetectHeader Select this option to automatically detect the header and footer in a document. DocumentType Select between Single-column, Multi-column, or Pleading Document type. ExtractHyperlinks Select this option to extract hyperlinks. ExtractImages Select this option to extract images. BCL Drake® 7.0 can save images as JPEGs and as BMPs. ExtractText Select this option if you want the text in your PDF documents to be extracted with all of its attributes. Fonts are mapped to the corresponding font. ImageFormat Specify output image format . JpegQuality Set the quality of JPEG images in the output, from 1 to 100%. MergeParagraph Select this option to merge lines of text into whole paragraphs. MergeText Select this option to merge individual words into lines of text. If this option is not selected, each word will be placed in a separate text box. PageFrom To do a page range conversion, set its value to the start page number; otherwise, set it 0 to do a whole document conversion. PageTo To do a page range conversion, set its value to the end page number; otherwise, set it 0 to do a whole document conversion. PasswordLen Non-negative number equal to the length of the Passwords string + 1. If PasswordLen is set to 0, Passwords is automatically set to NULL. Passwords List of passwords for opening and/or setting security permissions of encrypted files (user and/or owner passwords). If you use multiple passwords, you must include a non-NULL character separating the passwords, and specify the separating character in PasswordSeparator. PasswordSeparator Character used to separate multiple passwords in the Passwords string. PreserveTextPosition ConversionMethod takes precedence over this setting. If ConversionMethod is not used, this option will be used to determine whether the output contains text boxes. ShrinkFonts Selecting this option will ensure that all text fits within its original area on your screen. UsingPageRange If UsingPageRange is 0, then the program will ignore the set values for PageFrom and PageTo and do the whole document conversion (unless PageFrom and PageTo is set to 0).