Skip to main content

Search OfficeIMO

Enter a topic, API type, or PowerShell command.

Documentation Search all OfficeIMO/
Class

PdfDocumentAttachments

OfficeIMO.Pdf

Namespace
OfficeIMO.Pdf
Assembly
OfficeIMO.Pdf
Source revision
be6c300e4ab1 with working tree changes
Modifiers
sealed

Existing-document embedded and associated file editing operations.

Inheritance

  • object
  • PdfDocumentAttachments

Usage

Explore 1 API references to this type

This type appears in these public API surfaces even when no hand-authored example is attached directly to the page.

Returned or exposed by 1

Methods

public PdfAttachmentEditResult Add(PdfEmbeddedFile attachment) #

Adds one attachment.

Parameters

attachment OfficeIMO.Pdf.PdfEmbeddedFile required
public PdfAttachmentEditResult Edit(Action<PdfAttachmentEditSession> edit) #

Applies a transactional attachment collection edit.

Parameters

edit System.Action<OfficeIMO.Pdf.PdfAttachmentEditSession> required
Extract 2 overloads
public IReadOnlyList<PdfExtractedAttachment> Extract(PdfLoadOptions? readOptions = null) #

Extracts every embedded or associated file payload.

Parameters

readOptions OfficeIMO.Pdf.PdfLoadOptions? = null optional

Returns

IReadOnlyList<PdfExtractedAttachment>
public PdfExtractedAttachment Extract(PdfAttachmentInfo attachment, long maximumDecodedBytes, CancellationToken cancellationToken = default) #

Extracts one selected attachment without decoding unrelated payloads.

Parameters

attachment OfficeIMO.Pdf.PdfAttachmentInfo required
maximumDecodedBytes long required
cancellationToken System.Threading.CancellationToken = default optional
Remove 2 overloads
public PdfAttachmentEditResult Remove(string fileName) #

Removes one attachment.

Parameters

fileName string required
public PdfAttachmentEditResult Remove(PdfAttachmentInfo attachment) #

Removes one selected attachment by its source object identity.

Parameters

attachment OfficeIMO.Pdf.PdfAttachmentInfo required
public PdfAttachmentEditResult Rename(string fileName, string newFileName) #

Renames one attachment.

Parameters

fileName string required
newFileName string required
public PdfAttachmentEditResult Replace(string fileName, PdfEmbeddedFile replacement) #

Replaces one attachment by file name.

Parameters

fileName string required
replacement OfficeIMO.Pdf.PdfEmbeddedFile required