Topics   All   Mac OS X (Only)   Windows (Only)   Linux (Only, Not)   iOS (Only, Not)  
Components   Crossplatform Mac & Win   Server (Not)   Client   Old   Guides   Examples
New in version: 6.1   6.2   6.3   6.4   6.5   7.0   7.1   7.2   7.3   7.4    Statistic  

DynaPDF.AddBookmark

Adds a bookmark to the global outline tree of the document.

Component Version macOS Windows Server FileMaker Cloud FileMaker iOS SDK
DynaPDF 4.0 Yes Yes Yes Yes Yes

MBS( "DynaPDF.AddBookmark"; PDF; Title; Parent; DestPage { ; Open } )

Parameters

Parameter Description Example value
PDF The PDF reference returned from DynaPDF.New. $pdf
Title Title of the bookmark "Chapter 2"
Parent The Parent bookmark or -1. -1
DestPage Destination page. 5
Open Optional
Optional, whether bookmark should appear open initially. Default is 0 for closed.
0

Result

Returns Handle of bookmark or error.

Description

Adds a bookmark to the global outline tree of the document.
It sets also the page mode to pmUseOutlines (see DynaPDF.SetPageMode). If the outline tree should not be shown when opening the document, then set the page mode back to pmUseNone or any other value before closing the PDF file.
Parent can be a handle of another bookmark if it should be added as a child of this bookmark. If Parent is set to -1 the bookmark is added as a root node.
DestPage specifies the page that should be opened when clicking on the bookmark. The parameter can be set to a page number that does not yet exist. If the page does not exist when closing file then it is adjusted to page number 1.
The parameter Open specifies whether a bookmark node should appear open or closed when it contains children. When a bookmark contains no children then this parameter should be set to false.

Related functions: DynaPDF.AddBookmarkEx, DynaPDF.ChangeBookmark, DynaPDF.InsertBookmark, DynaPDF.InsertBookmarkEx, DynaPDF.SetBookmarkDest, DynaPDF.SetBookmarkStyle.

See also AddBookmark function in DynaPDF manual.

Examples

Add a bookmark to link to page 5

MBS( "DynaPDF.AddBookmark"; $PDF; "Test"; -1; 5; 0 )

See also

Example Databases


DynaPDF.AddAnnotToPage   -   DynaPDF.AddBookmarkEx

Feedback: Report problem or ask question.




Links
MBS Xojo PDF Plugins