50
activePDF Toolkit Professional Edition
aptkl4a 30405
Copyright 2005, activePDF, Inc. All Rights Reserved.
Page 36 of 553
symbol ¶.
6=Insert. An insert tag appears as a solid up arrow "^"
Flags
Long
Controls the behavior of the comment. Values are:
2=Hidden (no view OR print)
4=Print
8=No zooming. Zooming does not affect appearance.
16 = No rotate. Do not rotate the appearance to match the
page's rotation.
32 = No View. Hidden on screen, but printable.
64 = Readonly. Contents cannot be changed.
128 = Locked. The comment properties cannot be deleted,
but contents can be changed.
256 = ToggleNoView. This is largely implementation
dependent.
Values can be "or'ed" together: Flags = 4 or 64.
Color
String
The color of the comment you want to add to your PDF. PDF
comment color (controls color of the comment icon and top
bar of popup window.) Alternately, you can use hex codes.
NOTE:
Hex codes must be pre-pended with the pound sign
(#) e.g. #FF0000.
Refer to Appendix F: Supported Comment Colors for a list of
values.
Opened
Variant_Bool
Sets the initial view setting of the comment to "open" or
"closed".
True = Open - Icon and comment displayed.
False = Closed - Icon only.
PageNum
Long
The page on which the comment appears. If you specify 0,
Toolkit adds the comment to the cover page.
Example
Set TK = CreateObject("APToolkit.Object")
r = TK.OpenOutputFile("output.pdf")
r = TK.OpenInputFile("input.pdf")
TK.AddComment 30, 562, 200, 200, "This is a test comment", "Test", 2, 16, "#006600",
false, 1
TK.CopyForm 0, 0
TK.CloseOutputFile
Set TK = Nothing
How to C#: Modify Image Metadata (tag) edit, C#.NET PDF pages extract, copy, paste, C#.NET rotate PDF pages, C#.NET search text in PDF, C#.NET edit PDF bookmark, C#.NET edit PDF metadata, C#.NET
batch pdf metadata editor; pdf metadata reader
59
activePDF Toolkit Professional Edition
aptkl4a 30405
Copyright 2005, activePDF, Inc. All Rights Reserved.
Page 37 of 553
AddExternalLink
Description
AddExternalLink instructs Toolkit to add a link in the current output file that connects to a specified
designation in an external PDF document.
Return type
None
Syntax
object.
AddExternalLink
PageNbr, LLX, LLY, URX, URY, DestFileName, DestPage, DestLLX,
DestLLY, Style
The AddExternalLink method has these required parts:
Part
Value Type
Description
Object
None
An expression of the Toolkit object.
PageNbr
Long
The page in the new PDF. (Use -1 when adding links during
CopyForm or MergeFile operations.)
LLX
Short
The horizontal position of the lower-left corner of the link.
Uses the PDF Coordinate System.
LLY
Short
The vertical position of the lower-left corner of the link. Uses
the PDF Coordinate System .
URX
Short
The horizontal position of the upper-right corner of the link.
Uses the PDF Coordinate System.
URY
Short
The vertical position of the upper-right corner of the link.
Uses the PDF Coordinate System.
DestFileName
String
The full path to the external PDF file.
DestPage
Long
The page number in the external PDF file containing the
destination.
DestLLX
Short
The horizontal position for the linked destination's lower-left
corner in the external PDF file. Uses the PDF Coordinate
System.
DestLLY
Short
The vertical position for the linked destination's lower-left
corner in the external PDF file. Uses the PDF Coordinate
System.
16
activePDF Toolkit Professional Edition
aptkl4a 30405
Copyright 2005, activePDF, Inc. All Rights Reserved.
Page 38 of 553
Style
Short
Box style of the link.
Values are:
-1 = Invisible
0=Black solid
1=Red dashed
2=Red solid
3=Green dashed
4=Green solid
5=Blue dashed
6=Blue solid
How to C#: Basic SDK Concept of XDoc.PDF for .NET XDoc.PDF for .NET supports editing PDF document metadata, like Title, Subject, Author, Creator, Producer, Keywords, Created Date, and Last Modified Date.
online pdf metadata viewer; acrobat pdf additional metadata
43
activePDF Toolkit Professional Edition
aptkl4a 30405
Copyright 2005, activePDF, Inc. All Rights Reserved.
Page 39 of 553
AddExternalLinkBookmark
Description
AddExternalLinkBookmark instructs Toolkit to create a bookmark in the current output file that
connects to a specified designation in an external PDF document.
Return type
None
Syntax
object.
AddExternalLinkBookmark
BookmarkText, DestFileName, DestPage, DestLLX, DestLLY
The AddExternalLinkBookmark method has these required parts:
Part
Value Type
Description
Object
An expression of the Toolkit object.
BookmarkText
String
The text to add as a bookmark.
DestFileName
String
The full path to the external PDF file.
DestPage
Long
The destination page number in the external PDF file.
DestLLX
Short
The horizontal position for the linked destination's lower-left
corner in the external PDF file. Uses the PDF Coordinate
System.
DestLLY
Short
The vertical position for the linked destination's lower-left
corner in the external PDF file. Uses the PDF Coordinate
System.
Remarks
You can generate bookmarks after adding a page. By default, Toolkit generates bookmarks at the
highest level of the topic tree. You can call GotoNextBookmarkLevel or GotoPreviousBookmarkLevel
prior to any bookmark method to control its level in the tree.
58
activePDF Toolkit Professional Edition
aptkl4a 30405
Copyright 2005, activePDF, Inc. All Rights Reserved.
Page 40 of 553
AddField
Description
AddField instructs Toolkit to add one of several types of form fields to your PDF at the specified
location. You can also control the field name, height and width, and the font name and size.
NOTE:
Toolkit writes the form fields to the PDF when you call CloseOutputFile.
Syntax
object.
AddField
PageNumber, FieldType, FieldName, LLX, LLY, Width, Height, FontName,
FontSize
The AddField method has these required parts:
Part
Value Type
Description
PageNumber
Int
The specified page number in the output PDF on which Toolkit
will add the form field.
FieldType
Int
The type of form field Toolkit will create in the output PDF.
Values are:
1=Text field
2=Signature
3=Push button
4=Checkbox
5=Radio button
6=Combo box
7=List box
FieldName
String
The name of the form field.
LLX
Float
The horizontal position of the lower-left corner of the form field.
Uses thePDF Coordinate System .
LLY
Float
The vertical position of the lower-left corner of the form field.
Uses the PDF Coordinate System.
Width
Float
The width of the form field.
Height
Float
The height of the form field.
FontName
String
The font used in the form field.
NOTE:
You must set the encoding for the font. Refer to the
SetFont method for details and a list of appropriate
parameters.
7
activePDF Toolkit Professional Edition
aptkl4a 30405
Copyright 2005, activePDF, Inc. All Rights Reserved.
Page 41 of 553
FontSize
Float
The size of the font. Refer to SetFont for details.
54
activePDF Toolkit Professional Edition
aptkl4a 30405
Copyright 2005, activePDF, Inc. All Rights Reserved.
Page 42 of 553
AddHyperlink
Description
AddHyperlink instructs Toolkit to add a hyperlink in the current output file that connects to a specified
URL. When clicked, the URL opens in a new browser window.
Return type
None
Syntax
object.
AddHyperlink
PageNbr, LLX, LLY, URX, URY, DestURL, Style
The AddHyperlink method has these required parts:
Part
Value Type
Description
Object
An expression of the Toolkit object.
PageNbr
Long
0 = The action will take place on the new or current open output
page. (Default)
>1 = The action will occur on the specified page number.
-1 = The action will occur on all pages.
LLX
Short
The horizontal position of the lower-left corner of the link. Uses the
PDF Coordinate System.
LLY
Short
The vertical position of the lower-left corner of the link. Uses the PDF
Coordinate System.
URX
Short
The horizontal position of the upper-right corner of the link. Uses the
PDF Coordinate System.
URY
Short
The vertical position of the upper-right corner of the link. Uses the
PDF Coordinate System.
DestURL
String
The full path to the destination URL.
Style
Short
Box style of the link.
-1 = Invisible
0=Black solid
1=Red dashed
2=Red solid
3=Green dashed
4=Green solid
27
activePDF Toolkit Professional Edition
aptkl4a 30405
Copyright 2005, activePDF, Inc. All Rights Reserved.
Page 43 of 553
5=Blue dashed
6=Blue solid
Example
'AddHyperlink Example
Set TK = CreateObject("APToolkit.Object")
r = TK.OpenOutputFile("AddHyperlink.pdf")
'Set the font and color for our visable text
strFontSize = 20
TK.SetFont "Helvetica", strFontSize, 0
TK.SetTextColor 0, 0, 255, 0, 0
'Get the width of the text so we know how wide to make the link
strLinkText = "www.activePDF.com"
strTextWidth = TK.GetTextWidth(strLinkText, 0)
'Print the text that will show for the link
strLLX = 30
strLLY = 740
TK.PrintText strLLX, strLLY, strLinkText, 0
'Add the Hypderlink over the recently placed text
strURL = "http://www.activepdf.com"
TK.AddHyperlink 0, strLLX, strLLY, strLLX + strTextWidth, strLLY +
strFontSize, strURL, 0
TK.CloseOutputFile
Set TK = Nothing
58
activePDF Toolkit Professional Edition
aptkl4a 30405
Copyright 2005, activePDF, Inc. All Rights Reserved.
Page 44 of 553
AddInternalLink
Description
AddInternalLink instructs Toolkit to add a link that connects to a specified designation in PDF document
in the current output file.
Return type
None
Syntax
object.
AddInternalLink
PageNbr, LLX, LLY, URX, URY, DestPage, DestLLX, DestLLY, Style
The AddInternalLink method has these required parts:
Part
Value Type
Description
Object
An expression of the Toolkit object.
PageNbr
Long
The page to place the hyperlink on the outputted PDF. (Use -1
when adding links during CopyForm or MergeFile operations.)
LLX
Short
The horizontal position of the lower-left corner of the link. Uses
the PDF Coordinate System .
LLY
Short
The vertical position of the lower-left corner of the link. Uses the
PDF Coordinate System.
URX
Short
The horizontal position of the upper-right corner of the link. Uses
the PDF Coordinate System .
URY
Short
The vertical position of the upper-right corner of the link. Uses
the PDF Coordinate System .
DestPage
Long
The page number in the current output PDF containing the
destination.
DestLLX
Short
The horizontal position for the linked destination's lower-left
corner. Uses the PDF Coordinate System .
DestLLY
Short
The vertical position for the linked destination's lower-left corner.
Uses the PDF Coordinate System.
Style
Short
Box style of the link.
-1 = Invisible
0=Black solid
1=Red dashed
Documents you may be interested
Documents you may be interested