VpeSetDevYResolution

<< Click to Display Table of Contents >>

Navigation:  Device Control Properties >

VpeSetDevYResolution

Previous pageReturn to chapter overviewNext page

[Windows platform only; not supported by the Community Edition]

Sets the y-resolution in dots per inch for the currently selected output device. If the output device initializes this property, the DevPrintQuality property specifies the x-resolution, in dots per inch (DPI), of the printer.

int VpeSetDevYResolution(

VpeHandle hDoc,

int yres

)

VpeHandle hDoc

Document Handle

int yres

the y-resolution in DPI

Returns:

Value

Description

True

success

False

failure

Remarks:

In case of an error, LastError is set to VERR_COMMON. An error may occur if the device does not support setting the y-resolution. You should read this property’s value after setting it, to be sure the value has been accepted. Sometimes the value has not been accepted, but LastError returns no error state (= VERR_OK).

 

We experienced that some drivers do not allow setting the y-resolution, BEFORE the x-resolution had been changed and vice versa. Also some drivers only accept the same values for both resolutions.

Example:

VpeSetDevPrintQuality(hDoc, 300)        // 300 DPI

VpeSetDevYResolution(hDoc, 300)        // 300 DPI