SaveAttachment
Leave feedback
On this page
Saves attachment file to destination stream.
public void SaveAttachment(Attachment attachment, Stream destination,
CancellationToken cancellationToken)
| Parameter | Type | Description |
|---|---|---|
| attachment | Attachment | The attachment. |
| destination | Stream | The writable stream. |
| cancellationToken | CancellationToken | Cancellation token. |
| exception | condition |
|---|---|
| ArgumentNullException | Thrown when attachment is null. |
| ArgumentNullException | Thrown when destination is null. |
| PasswordRequiredException | Thrown when password is required to open the document. |
| IncorrectPasswordException | Thrown when password that was specified is incorrect. |
| GroupDocsViewerException | Thrown when attachment could not be found. |
Learn more
- Learn more about getting document attachments in C#: How to get list of document attachments using GroupDocs.Viewer
- Learn more about saving document attachments in C#: How to save document attachments using GroupDocs.Viewer
- class Attachment
- class Viewer
- namespace GroupDocs.Viewer
- assembly GroupDocs.Viewer
Saves attachment file to destination stream.
public void SaveAttachment(Attachment attachment, Stream destination)
| Parameter | Type | Description |
|---|---|---|
| attachment | Attachment | The attachment. |
| destination | Stream | The writable stream. |
| exception | condition |
|---|---|
| ArgumentNullException | Thrown when attachment is null. |
| ArgumentNullException | Thrown when destination is null. |
| PasswordRequiredException | Thrown when password is required to open the document. |
| IncorrectPasswordException | Thrown when password that was specified is incorrect. |
| GroupDocsViewerException | Thrown when attachment could not be found. |
Learn more
- Learn more about getting document attachments in C#: How to get list of document attachments using GroupDocs.Viewer
- Learn more about saving document attachments in C#: How to save document attachments using GroupDocs.Viewer
- class Attachment
- class Viewer
- namespace GroupDocs.Viewer
- assembly GroupDocs.Viewer
Was this page helpful?
Any additional feedback you'd like to share with us?
Please tell us how we can improve this page.
Thank you for your feedback!
We value your opinion. Your feedback will help us improve our documentation.