property LinkAnnotation[PageNumber, Index: Integer]: TLinkAnnotation; // read only
Indexed read-only property that returns the explicit /Annot Subtype Link at the given index, including the target action or destination
Needs Active to be True. PageNumber is 1-based (1 .. PageCount) and Index runs 0 .. LinkAnnotationCount[PageNumber] - 1
The returned record is a snapshot of the value at the time of the call; subsequent edits to the document do not modify previously returned records
Reading another page does not change PageNumber: the page is opened only for the call, so its page actions do not run and the current page keeps its state. For such a page the record's Handle is nil, because the native link handle does not outlive that temporary page
| PageNumber | One-based page number (1 .. PageCount) |
| Index | Zero-based link index in 0 .. LinkAnnotationCount[PageNumber] - 1 |
/Annots array
var
I: Integer;
begin
if not Pdf1.Active then Exit;
for I := 0 to Pdf1.LinkAnnotationCount[1] - 1 do
begin
// inspect Pdf1.LinkAnnotation[1, I]
Memo1.Lines.Add(IntToStr(I));
end;
end;
ActionPath supplies UTF-8-decoded URI action targets; the required terminator is included in the native buffer but omitted from the returned string