vpdf_LoadPageIntoDIB

 

vpdf_LoadPageIntoDIB(hVPDF As Long, dwPageNumber As Integer, iXDPI As Integer, iYDPI As Integer, dwFlags As Integer) As Long

 

Description

 

The vpdf_LoadPageIntoDIB function reads the specified page from a PDF file and converts it into a bitmap (DIB) in the specified resolution.

 

Parameters

 

Long

hVPDF

Handle to a Vector PDF object.

Integer

dwPageNumber

The 0 based index of the page to load.

Integer

iXDPI

Horizontal resolution of the output image in dots per inch.

Integer

iYDPI

Vertical resolution of the output image in dots per inch.

Integer

dwFlags

Options for the bitmap conversion. The following values can be combined with the | operator:

 

BIVPDF_DRAW_ANNOTATIONS (2):

Also draw the annotations on the page.

 

BIVPDF_DRAW_FORMS (4):

Also draw any form controls on the page.

 

Annotations and form controls are related, but not the same. The PDF library can draw them separately.

Please see the following examples for setting the dwFlags parameter:

 

To only show the pdf without annotations or form controls, set the dwFlags parameter to 0:

 

To show annotations but not the form controls, set the dwFlags parameter to 2 (BIVPDF_DRAW_ANNOTATIONS):

 

To show the form controls but not the annotations, set the dwFlags parameter to 4 (BIVPDF_DRAW_FORMS):

 

To show both annotations and form controls, set the dwFlags parameter to 6 (BIVPDF_DRAW_ANNOTATIONS (2) + BIVPDF_DRAW_FORMS (4) = 6):

 

Return value

Returns a handle to the DIB, or NULL if an error occurred.