You are currently browsing legacy 3.0 version of documentation. Click here to switch to the newest 5.0 version.
GetAttachment can be used to download a single attachment.
Attachment GetAttachment(string key);
|key||string||key of the attachment you want to download|
|Attachment||Object that represents attachment.|
Attachment attachment = store .DatabaseCommands .GetAttachment("albums/holidays/sea.jpg"); // null if does not exist Stream data = attachment.Data();
GetAttachments can be used to download attachment information for multiple attachments.
AttachmentInformation GetAttachments(int start, Etag startEtag, int pageSize);
|start||int||Indicates how many attachments should be skipped|
|startEtag||Etag||ETag from which to start|
|batchSize||int||maximum number of attachments that will be downloaded|
|AttachmentInformation||Object that represents attachment metadata information.|
AttachmentInformation attachments = store .DatabaseCommands .GetAttachments(start: 0, startEtag: Etag.Empty, pageSize: 10);