GetObjectByPathCount
Document properties, Content Extraction
Description
Returns the element count of the node a path expression resolves to.
Syntax
Delphi
Function TPDFlib.GetObjectByPathCount(Const Path: WideString): Integer;Parameters
| Path | The path expression (see GetObjectByPath for the grammar). |
|---|
Return values
| -1 | The path does not resolve. |
|---|---|
| 0 | The node is a scalar. |
| N | The array length, or the entry count of a dictionary or stream dictionary. |
Example
for I:= 0 to PDF.GetObjectByPathCount('Root/Pages/Kids')- 1 do
ShowMessage(PDF.GetObjectByPath('Root/Pages/Kids['+ IntToStr(I)+ ']/Type', 2));