Xojo Developer Conference
25/27th April 2018 in Denver.
MBS Xojo Conference
6/7th September 2018 in Munich, Germany.

DynaPDF Manual - Page 238

Previous Page 237   Index   Next Page 239

Function Reference
Page 238 of 750
which the annotation can be found must be known if the target file is stored in a file attachment
annotation (parameter SrcPage). The first page number is denoted by 1.
The parameter Source specifies the source file if the embedded file is located in an external PDF file.
This parameter is only used if Location is set to eflExternal or eflExternalAnnot. It can be set to NULL
in all other cases.
The parameter Target is required; it specifies either the name of the embedded PDF file or the name
of the annotation in which the file is stored. The name of a file attachment annotation must be set
with SetAnnotString(). The names of all annotations in a page must be unique. The function does not
check whether the annotation or embedded file exists. Therefore, the target file can be embedded
before or after the action was created.
The name of an embedded file is the file name if it was attached with AttachFile() or AttachFileEx().
The function extracts the file name automatically if a path was passed to the function.
It is not allowed to use different string formats in AttachFile() or SetAnnotString() and in the
corresponding CreateGoToEAction() call. The same restriction applies to named destinations. If a file
was inserted with the Unicode version then you must use the Unicode version of
CreateGoToEAction() too. Otherwise the embedded file cannot be found.
The destination page that should be opened can be either specified directly with the parameter
DestPage or with a Named Destination (see CreateNamedDest() for further information). Named
destinations take precedence.
Remarks:
A path to an external PDF file should be defined as relative path. Actions must be added to a PDF
object with AddActionToObj().
Return values:
If the function succeeds the return value is the action handle, a value greater or equal zero. If the
function fails the return value is a negative error code.
CreateGoToRAction
Syntax:
SI32 pdfCreateGoToRAction(
const PPDF* IPDF,
// Instance pointer
const char* FileName, // File path to external PDF file
UI32 PageNum)
// Destination page
This function creates a go-to-remote action. A go-to-remote action opens an external PDF file and
jumps to the page defined by the parameter PageNum. If the destination page does not exist the first
page will be displayed.
 

Previous topic: CreateGoToEAction

Next topic: CreateGroupField