This sample shows how to remove XObjects, often used for watermarks and backgrounds, from PDF document pages.
Docotic.Pdf library provides access to the collection of page XObjects through the PdfPage.XObjects property. The value of the property is a PdfList object.
You can remove any XObject you no longer need using the PdfList.Remove or PdfList.RemoveAt method. The PdfList.Clear method removes all such objects.
Please note that XObjects are not always watermarks or backgrounds. A PDF file can use such objects for logos and other repeatable items, too.