On this page
Delete Annotations
You can remove all annotations from the current document by calling the removeAllAnnotations()
method.
- The return value is a boolean indicating whether the operation was successful.
Example code:
dart
CPDFReaderWidget(
document: documentPath,
configuration: CPDFConfiguration(),
onCreated: (controller) {
setState(() {
this.controller = controller;
});
},
)
bool deleteResult = await controller.document.removeAllAnnotations();
Note: This method does not delete hyperlink annotations.