PdfDocument.CreateFileAttachment Method (String)

Creates attachment from the specified file and returns file specification for the attachment.

Namespace:  BitMiracle.Docotic.Pdf
Assembly:  BitMiracle.Docotic.Pdf (in BitMiracle.Docotic.Pdf.dll)

Syntax

C#
public PdfFileSpecification CreateFileAttachment(
	string filePath
)
VB
Public Function CreateFileAttachment ( 
	filePath As String
) As PdfFileSpecification

Parameters

filePath
Type: System.String
The name of the file to create attachment from.

Return Value

Type: PdfFileSpecification
The newly created PdfFileSpecification for the attachment.

Remarks

You can add returned file specifications to collection of document-level attachments (see SharedAttachments) or use it in a file attachment annotation (see AddFileAnnotation(PdfRectangle, PdfFileSpecification)).

See Also