Table of Contents

Enum PdfAttachmentIcon

Namespace
Syncfusion.Pdf.Interactive
Assembly
Syncfusion.Pdf.Portable.dll

Specifies the type of icon to be used in displaying file attachment annotations.

public enum PdfAttachmentIcon

Fields

Graph = 2

Type of icon used in file attachment annotation.

Paperclip = 3

Type of icon used in file attachment annotation.

PushPin = 0

Type of icon used in file attachment annotation.

Tag = 1

Type of icon used in file attachment annotation.

Examples

//Create a new PDF document.
PdfDocument document = new PdfDocument();
//Create a new page.
PdfPage page = document.Pages.Add();
//Create a new rectangle
RectangleF attachmentRectangle = new RectangleF(10, 40, 30, 30);
//Create a new attachment annotation.
PdfAttachmentAnnotation attachmentAnnotation = new PdfAttachmentAnnotation(attachmentRectangle, @"Input.jpg");
//Set the Attachment icon to attachment annotation.
attachmentAnnotation.Icon = PdfAttachmentIcon.PushPin;
//Add this annotation to a new page.
page.Annotations.Add(attachmentAnnotation);
//Save the  document to disk.
document.Save("Output.pdf");
//close the document
document.Close(true);
'Create a new PDF document.
Dim document As New PdfDocument()
'Create a new page.
Dim page As PdfPage = document.Pages.Add()
'Create a new rectangle
Dim attachmentRectangle As New RectangleF(10, 40, 30, 30)
'Create a new attachment annotation.
Dim attachmentAnnotation As New PdfAttachmentAnnotation(attachmentRectangle, "Input.jpg")
'Set the Attachment icon to attachment annotation.
attachmentAnnotation.Icon = PdfAttachmentIcon.PushPin
'Add this annotation to a new page.
page.Annotations.Add(attachmentAnnotation)
'Save the  document to disk.
document.Save("Output.pdf")
'close the document
document.Close(True)

See Also