Microsoft Word (DOCX/DOC) documents are frequently used to exchange information. Sometimes a watermark is added on the document to show ownership or purpose of the document. There could be different possible use cases, whereas we will be learning following scenarios in this blog post:
- Insert Watermark Text in Word Document (DOCX/DOC)
- Insert Watermark Image in Word Document (DOCX/DOC)
- Remove Watermark from Word Document (DOCX/DOC)
Insert Watermark Text in Microsoft Word Document (DOCX/DOC)
With Aspose.Words Cloud API, you only need to set text and the rotation angle, where the rotation angle works in the clockwise direction. Following C# code snippet inserts text in all pages of the DOCX or DOC document.
Below screenshot shows output file in Print Preview window:
Add Watermark Image in Word Document (DOCX/DOC)
Images are also used as watermark in Microsoft Word Documents. If you want to set an image watermark then below code snippet can be used to achieve these requirements.
This API call will set the image at the specified angle in the middle of the page. The following is a screenshot of Print Preview for the output document after inserting image.
Delete Watermark from Microsoft Word Document (DOCX/DOC)
Aspose.Words Cloud API offers the most exclusive features to manipulate word documents. You can delete watermarks with single API call. Below code snippet can be used to remove it efficiently:
It is important to note here that the API will remove the most recent or last watermark applied to the document. Therefore, in case there is more than one appearance or kind of it in a document, let us say an image and some text, then you would need to call the API twice.
This is a detailed overview of the feature. Many other features are also offered by the API. You can get familiar with those and stay updated by visiting Blogs section. In case of any concerns, you can always get in touch with us. Write to us at Free Support Forums and we would love to help you.