PdfContentEditor.AddDocumentAttachment

AddDocumentAttachment(string, string)

Adds document attachment with no annotation.

public void AddDocumentAttachment(string fileAttachmentPath, string description)
ParameterTypeDescription
fileAttachmentPathStringThe path of the file will be attached.
descriptionStringThe description information.

Examples

PdfContentEditor editor = new PdfContentEditor();
editor.BindPdf("example.pdf");
editor.AddDocumentAttachment("attachment_file.pdf", "description of attachment_file");
editor.Save("example_out.pdf");

See Also


AddDocumentAttachment(Stream, string, string)

Adds document attachment with no annotation.

public void AddDocumentAttachment(Stream fileAttachmentStream, string fileAttachmentName, 
    string description)
ParameterTypeDescription
fileAttachmentStreamStreamThe stream of the file will be attached.
fileAttachmentNameStringThe attachment name.
descriptionStringThe description information.

Examples

PdfContentEditor editor = new PdfContentEditor();
editor.BindPdf("example.pdf");
using(System.IO.FileStream attStream = System.IO.File.OpenRead("attachment_file.pdf"))
{
    editor.AddDocumentAttachment(attStream, "attachment_file.pdf", "description of attachment_file");
    editor.Save("example_out.pdf");
}    

See Also