This article describes a method to conditionally remove a watermark in a Word template created with DocumentsCorePack (DCP).
The method involves setting up a watermark using the standard Word feature, then defining conditions for when to remove the watermark in the Advanced template settings. In this example, the watermark is removed when the quote is set to active.
Add Watermark: In order to add a watermark to a template, you can use the built-in feature in Microsoft Word. In this specific example, the watermark being added is a red word “draft” to a quote template.
Configure “Remove Watermark”:
- Open the Advanced template settings by opening the [Insert Mail Merge fields]-Taskbar -> [Advanced template settings].
- In the settings, you can find an option called [Remove Watermark]. This lets you choose when the watermark will be removed. In this case, it’s set to “If the quote is active”, which means that if the quote is in draft or inactive, the watermark will be there. If the quote is active it will not be visible.
Result: When we run this template against an active quote, we can see that the generated document does not show the “draft” watermark.
That’s it! We appreciate your feedback! Please share your thoughts by sending an email to email@example.com!