DynaPDF Manual - Page 283

Previous Page 282   Index   Next Page 284

Function Reference
Page 283 of 839
SI32 pdfCreateNamedDest(
const PPDF* IPDF,
// Instance pointer
const char* Name,
// Name of the destination (byte string)
UI32 DestPage,
// Destination page
TDestType DestType, // Destination type
double a,
// Various, depends on destination type
double b,
// Various, depends on destination type
double c,
// Various, depends on destination type
double d)
// Various, depends on destination type
The function creates a named destination that can be accessed from external PDF files. Named
destinations are useful if the destination must be accessed from another PDF file. For example, a link
to the beginning of Chapter 3 in another document might refer to the destination by a name, such as
Chap3.begin, instead of an explicit page number in the other document. This makes it possible to
change the destination in the document without invalidating the external link.
Named destinations can be used in the same document by bookmarks, page links, and go-to actions.
Named destinations which are located in another document can be accessed with a go-to-remote
action (see CreateGoToRActionEx() for further information).
The different destination types are described in detail at CreateGoToAction().
Make sure that the same string format is used in a named destination and in a go-to remote action
that tries to access it. Note that the destination cannot be found if the string format is different, e.g.
Ansi in the named destination and Unicode in the go-to remote action.
To avoid unnecessary issues it is usually best to use 7 bit Ansi strings for named destinations.
Return values:
If the function succeeds the return value is the destination handle, a value greater or equal zero. If
the function fails the return value is a negative error code.

Previous topic: CreateNamedAction

Next topic: CreateNewPDF