Delete
Removes annotation from document.
Syntax
expression.Delete();
expression - A variable that represents a ApiBaseAnnotation class.
Parameters
This method doesn't have any parameters.
Returns
boolean
Example
This example removes the square annotation from document.
- Code
- Result
let doc = Api.GetDocument();
let squareAnnot = Api.CreateSquareAnnot([10, 10, 160, 32]);
let page = doc.GetPage(0);
page.AddObject(squareAnnot);
squareAnnot.SetBorderStyle("dashed");
squareAnnot.SetDashPattern([8, 4, 4, 4]);
squareAnnot.Delete();