PDF-XChange - Tracker PDF Viewer - TIFF-XChange - Image-XChange - XMF-XChange - Raster-XChange - Support

Moderators: TrackerSupp-Daniel, Tracker Support, Chris - Tracker Supp, Vasyl-Tracker Dev Team, Sean - Tracker, Tracker Supp-Stefan

 
rahulmr
User
Topic Author
Posts: 3
Joined: Fri Apr 13, 2018 10:52 am

Multiple watermark additions using the api

Fri Apr 13, 2018 10:55 am

Hi,

I am using the PXCComLib.CPXCControlEx to create a printer object using windev and was trying to apply watermarks to that. I was able to
add the watermark but it was working only for single watermark.
The following is the code snippet. It works for a single watermark but multiple watermarks cannot be added.When used as single watermarks both works.

gPrinter is a dynamic object in windev which refers to the printer created using

gPrinter = gFactory>>Printer("", "PDF-XChange Test", "", "")

gPrinter>>Option("Watermarks.Enabled")=True
gPrinter>>AddTextWatermark("WM", "HelloWaterMark 0", "Verdana", 400, True, False,0, 0, 0, 8, 100,100,0,100,30,0,"1,2")
gPrinter>>AddTextWatermark("WM1", "Hello WaterMark 1", "Verdana", 400, True, False,0, 0, 0, 1, 0,0,45,100,30,0,"1,2")

I tried setting using these two options

gPrinter>>Option("Watermarks.Watermarks")="WM,WM1"
gPrinter>>Option("Watermarks.Watermarks","WM,WM1")

I am not quite sure about the details what is given in PDF manual in sections watermark

"Watermarks String A comma to separate the list of watermark names should be added to the document.Each of these watermark should be added using AddTextWatermark or AddImageWatermark methods.Default value: empty string."
 
rahulmr
User
Topic Author
Posts: 3
Joined: Fri Apr 13, 2018 10:52 am

Re: Multiple watermark additions using the api

Mon Apr 16, 2018 6:32 am

it works when you add ; and not , (semicolon instead of comma
 
User avatar
Tracker Supp-Stefan
Site Admin
Posts: 13076
Joined: Mon Jan 12, 2009 8:07 am
Location: London
Contact:

Re: Multiple watermark additions using the api

Mon Apr 16, 2018 10:01 am

Hello rahulmr,

Thanks for pointing the right syntax. As discussed over e-mails - I will pass this along to the people working on the Manuals so that it can be updated there too!

Regards,
Stefan
 
Sean - Tracker
Site Admin
Posts: 39
Joined: Wed Sep 14, 2016 5:42 pm
Location: Leitrim, Ireland

Re: Multiple watermark additions using the api

Mon Apr 16, 2018 5:27 pm

Hi rahulmr,

Thank you for pointing out the error in the manual - we have updated it now. If you have experience any issues similar to this in the future, then it may be worth checking the V5 (2012) and V6 manuals in order to cross-reference. Those manuals are available at these locations:

https://help.tracker-software.com/DEV/d ... n=drivers5

https://help.tracker-software.com/pdfxdapi6/

Sorry that you experienced this issue - please also don't hesitate to get in touch if you need assistance in the future, we are always here to help.

Sean Godley

Tracker Software Products, North America Office
Sean Godley
Technical Writer
Tracker Software Products (Canada) LTD
Sales: +1 (250) 324-1621
Fax: +1 (250) 324-1623

Who is online

Users browsing this forum: No registered users and 5 guests