This sample shows how to remove widgets from your PDF documents using Docotic.Pdf library.
There are two ways to remove widgets. You can use the PdfPage.Widgets property to access the collection of a page widgets. Then use the Remove, RemoveAt, and Clear methods of the PdfWidgetCollection class to remove the widgets you don’t need.
Another way is to enumerate the collection of document widgets using the PdfDocument.GetWidgets method. Then use the PdfDocument.RemoveWidget method to remove unwanted widgets.