Spire.PDF is a professional PDF library applied to creating, writing, editing, handling and reading PDF files without any external dependencies. Get free and professional technical support for Spire.PDF for .NET, Java, Android, C++, Python.

Tue Oct 18, 2022 11:58 am

When exporting Word document containing watermark to PDF, the watermark into the PDF is showed under the contents.

P.S : sorry, example file generated is too big to be added as an attachment...

QuentinSup
 
Posts: 47
Joined: Mon Oct 18, 2021 9:18 am

Wed Oct 19, 2022 6:02 am

Hello,

Thanks for your inquiry.
I simulated a file and tested your case using the latest version of the Spire.Doc Pack(hot fix) Version:10.10.4. But I didn't reproduce your question. If you are using an older version, I suggest you use this version to test again. If your problem persists after the test, to help us further investigate it, please provide us with your test documentation. You can attache it here or send it to us via email ([email protected]). Thank you in advance.

Sincerely,
Simple
E-iceblue support team
User avatar

Simple.Li
 
Posts: 248
Joined: Fri Jul 01, 2022 2:33 am

Thu Oct 20, 2022 1:30 pm

I use Spire.Office for JAVA 7.10.1, I don't know which version of Spire.Doc is included ?

Please notice that the watermark is added by programmation into the doc before the convertion into PDF.

QuentinSup
 
Posts: 47
Joined: Mon Oct 18, 2021 9:18 am

Fri Oct 21, 2022 6:09 am

Hello,

Thanks for your feedback.
I used the following code to add the watermark and save to PDF format. The watermark can be kept above the text. If your code is different from ours, in order to facilitate our further investigation, please provide us with your testing code as well as your input file. You can attach it here or send it to us via email ([email protected]). Thanks in advance.
Code: Select all
        Document doc = new Document("Test1.docx");
        Section section = doc.getSections().get(0);
        Paragraph paragraph = section.getParagraphs().get(0);
        //Add a Shape
        ShapeObject shape = paragraph.appendShape(140, 60, ShapeType.Text_Plain_Text);
        shape.setVerticalPosition(50);
        shape.setHorizontalPosition(100);
        shape.setRotation(315);
        shape.getWordArt().setText("Test");
        shape.setFillColor(Color.red);
        shape.setTextWrappingStyle(TextWrappingStyle.In_Front_Of_Text);
        shape.setLineStyle(ShapeLineStyle.Single);
        shape.setStrokeColor(new Color(255, 192, 192, 255));
        shape.setStrokeWeight(1);
         doc.saveToFile("result.pdf", FileFormat.PDF);


Sincerely,
Simple
E-iceblue support team
User avatar

Simple.Li
 
Posts: 248
Joined: Fri Jul 01, 2022 2:33 am

Mon Oct 24, 2022 9:32 am

Hello,

Could you please let us know how is your issue going? Thanks in advance for your feedback and time.

Sincerely,
Simple
E-iceblue support team
User avatar

Simple.Li
 
Posts: 248
Joined: Fri Jul 01, 2022 2:33 am

Return to Spire.PDF

cron