DARenderPageToVariant
Direct access functionality, Rendering and printing
Description
Renders the specified page from the specified document to an image and returns the image data as a byte array variant.
By default rendering uses the GDI+ system which is available in Windows XP and later.
Option 10, TIFF (G4) output, is only available on Windows Vista and Windows Server 2008 and later.
It is also possible to render using Cairo, use the SetCairoFileName and SelectRenderer
functions.
Syntax
ActiveX
Function PDFlib::DARenderPageToVariant(FileHandle As Long, PageRef As Long, Options As Long, DPI As Double) As VariantParameters
FileHandle
A handle returned by the DAOpenFile, DAOpenFileReadOnly or
DAOpenFromStream functions
PageRef
A page reference returned by the DAFindPage or DANewPage functions
Options
PDF_RENDER_BMP = 0 (BMP output), PDF_RENDER_JPEG = 1 (JPEG output), PDF_RENDER_WMF = 2 (WMF output), PDF_RENDER_EMF = 3 (EMF output), PDF_RENDER_EPS = 4 (EPS output), PDF_RENDER_PNG = 5 (PNG output), PDF_RENDER_GIF = 6 (GIF output), PDF_RENDER_TIFF_RGB = 7 (TIFF output), PDF_RENDER_EMFPLUS = 8 (EMF+ output), PDF_RENDER_HTML5 = 9 (HTML5 output), PDF_RENDER_TIFF_G4 = 10 (G4 TIFF output), PDF_RENDER_EMF_DUAL = 11 (EMF+ Dual output)
DPI
The DPI to use when rendering the page. Values over 300 will cause excessive memory usage.