Creating Documents Having Different File Formats

The LEADTOOLS Document Writers SDK can create the following types of file formats:

Before using the LEADTOOLS Document Writers SDK, unlock it using L_SetLicenseFile. If you want to use the PDF format you must also unlock PDF support with L_SetLicenseFile.

Initialize the LEADTOOLS Document Writers SDK by calling L_DocWriterInit. In addition to initialization this function creates the document handle and sets the format type and format options for the file being created. Each format has its own specific options. These options are passed when the L_DocWriterInit function is called.

The L_DocWriterInit function also sets the progress callback function which shows the job's progress. The callback function must adhere to the function prototype described in the STATUSCALLBACK function.

To add a page to a new document file, call the L_DocWriterAddPage. This function uses the data in the DOCWRTPAGE structure,which provides information about the page to be inserted. It should have a valid EMF handle for the page to be created. When creating a PDF file an overlay image can be added to the inserted page if the bitmap handle member at DOCWRTPAGE has valid data and DOCWRTPDFOPTIONS is correctly initialized.

Use the L_DocWriterConvert function to convert a file from the LEADTOOLS Temporary Document (LTD) format to any of the listed document file formats. Conversion from LTD format to LTD format is not permitted.

After adding all of the new pages, call the L_DocWriterFinish function to finish file writing and create the document file. This function also frees all allocated resources.

Use the HyperText Markup Language (HTML) (part of the Document Writers SDK) when you want to write HTML. If you want to rasterize the file, use the HTML format that is part of the Document toolkit.

Help Version 20.0.2018.2.25
Products | Support | Contact Us | Copyright Notices
© 1991-2018 LEAD Technologies, Inc. All Rights Reserved.
LEADTOOLS Raster Imaging C API Help