CreatePolyLineAnnot
Creates polyline annotation.
Syntax
expression.CreatePolyLineAnnot(rect, path);
expression - A variable that represents a Api class.
Parameters
| Name | Required/Optional | Data type | Default | Description |
|---|---|---|---|---|
| rect | Required | Rect | annotation rect. | |
| path | Required | Path | polyline path |
Returns
Example
This example creates a polyline annotation and adds it to the page.
- Code
- Result
let doc = Api.GetDocument();
let polylineAnnot = Api.CreatePolyLineAnnot([40, 40, 200, 200], [{x: 100, y: 100}, {x: 150, y: 150}, {x: 100, y: 150}]);
let page = doc.GetPage(0);
page.AddObject(polylineAnnot);