BCL easyPDF SDK
easyPDF SDK Usermanual
PDF Creator Programming API  |  Download Free Trial  |  Contact Us to Purchase

WatermarkHPosition Property

Gets/Sets watermark horizontal placement setting.

Property WatermarkHPosition(Index As Long) As prnWmarkHPosition

prnWmarkHPosition get_WatermarkHPosition(int Index)
void set_WatermarkHPosition(int Index, prnWmarkHPosition value)

prnWmarkHPosition getWatermarkHPosition(int Index) throws PrinterException
void setWatermarkHPosition(int Index, prnWmarkHPosition value) throws PrinterException

Type

prnWmarkHPosition

Parameters

Remarks

N/A.

Example Usage

Set oPrinter = CreateObject("easyPDF.Printer.8")
Set oPrintJob = oPrinter.PrintJob
Set oPDFSetting = oPrintJob.PDFSetting

oPDFSetting.Watermark(0) = True
oPDFSetting.WatermarkAngle(0) = 0
oPDFSetting.WatermarkFontSize(0) = 72

' place the text (two lines, center aligned)
' at 0.5 inch from the top-left corner

oPDFSetting.WatermarkText(0) = "SDK Sample" + vbCr + vbLf + "2nd Line"
oPDFSetting.WatermarkHPosition(0) = PRN_WMARK_HPOS_LEFT
oPDFSetting.WatermarkVPosition(0) = PRN_WMARK_VPOS_TOP
oPDFSetting.WatermarkTextAlignment(0) = PRN_WMARK_ALIGN_CENTER
oPDFSetting.WatermarkHOffset(0) = 0.5
oPDFSetting.WatermarkVOffset(0) = 0.5

oPrintJob.PrintOut "C:\test\input.doc", "C:\test\output.pdf"