Debenu Quick PDF logo

SetOutlineRemoteDestination

Outlines

Version history

This function was introduced in Quick PDF Library version 7.22.

Description

Sets the outline item (bookmark) to open another PDF when it is clicked.

The opening page number and various sizing/positioning values can be specified.

Note: because the page size of the target document is not known, all positions are specified in points measured from the bottom left corner of the opening page.

Syntax

Delphi

function TDebenuPDFLibrary1511.SetOutlineRemoteDestination(OutlineID: Integer; 
  FileName: WideString; OpenPage, Zoom, DestType: Integer; PntLeft, PntTop, 
  PntRight, PntBottom: Double; NewWindow: Integer): Integer;

ActiveX

Function DebenuPDFLibrary1511.PDFLibrary::SetOutlineRemoteDestination(
  OutlineID As Long, FileName As String, OpenPage As Long, Zoom As Long,
  DestType As Long, PntLeft As Double, PntTop As Double,
  PntRight As Double, PntBottom As Double, NewWindow As Long) As Long

DLL

int DPLSetOutlineRemoteDestination(int InstanceID, int OutlineID,
  wchar_t * FileName, int OpenPage, int Zoom, int DestType,
  double PntLeft, double PntTop, double PntRight, double PntBottom,
  int NewWindow)

Parameters

OutlineID The ID of the outline as returned by the NewOutline function. Alternatively, use the GetOutlineID function to get a valid outline ID.
FileName The filename of the PDF document to open when the outline is clicked. This should be in a specific format. Back slashes should be converted to forward slashes and the drive, if any, should be specified as just the drive letter between forward slashes without a colon. For example, the file "c:\my documents\hello.pdf" should be specified as "/c/my documents/hello.pdf". Relative path names are valid, including paths that include the ".." operator to move up a directory.
OpenPage The page number to jump to when the target document is opened. The first page has an index of zero (0).
Zoom The zoom percentage to use when the document is opened, valid values from 0 to 6400. Only used for DestType = 1, should be set to 0 for other DestTypes.
DestType 1 = "XYZ" - the target page is positioned at the point specified by the Left and Top parameters. The Zoom parameter specifies the zoom percentage.
2 = "Fit" - the entire page is zoomed to fit the window. None of the other parameters are used and should be set to zero.
3 = "FitH" - the page is zoomed so that the entire width of the page is visible. The height of the page may be greater or less than the height of the window. The page is positioned at the vertical position specified by the Top parameter.
4 = "FitV" - the page is zoomed so that the entire height of the page can be seen. The width of the page may be greater or less than the width of the window. The page is positioned at the horizontal position specified by the Left parameter.
5 = "FitR" - the page is zoomed so that a certain rectangle on the page is visible. The Left, Top, Right and Bottom parameters define the rectangular area on the page.
6 = "FitB" - the page is zoomed so that it's bounding box is visible.
7 = "FitBH" - the page is positioned vertically at the position specified by the Top parameter. The page is zoomed so that the entire width of the page's bounding box is visible.
8 = "FitBV" - the page is positioned at the horizontal position specified by the Left parameter. The page is zoomed just enough to fit the entire height of the bounding box into the window.
PntLeft The horizontal position used by DestType = 1, 4, 5 and 8. The position is specified in points measured from the bottom left corner of the target document's page.
PntTop The vertical position used by DestType = 1, 3, 5 and 7. The position is specified in points measured from the bottom left corner of the target document's page.
PntRight The horizontal position of the righthand edge of the rectangle. Used by DestType = 5. The position is specified in points measured from the bottom left corner of the target document's page.
PntBottom The horizontal position of the bottom of the rectangle. Used by DestType = 5. The position is specified in points measured from the bottom left corner of the target document's page.
NewWindow 0 = Replace the current document with the target document
1 = Open the target document in a new window unless the user has specified a different preference in the PDF viewer

Return values

0 The OutlineID was invalid
1 The outline destination was set successfully

Copyright © 2014 Debenu. All rights reserved. AboutContactBlogNewsletterSupport