AttachmentsExtensions.GetAttachmentAsync Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
GetAttachment.
public static System.Threading.Tasks.Task<byte[]> GetAttachmentAsync (this Microsoft.Bot.Connector.IAttachments operations, string attachmentId, string viewId, System.Threading.CancellationToken cancellationToken = default);
public static System.Threading.Tasks.Task<System.IO.Stream> GetAttachmentAsync (this Microsoft.Bot.Connector.IAttachments operations, string attachmentId, string viewId, System.Threading.CancellationToken cancellationToken = default);
static member GetAttachmentAsync : Microsoft.Bot.Connector.IAttachments * string * string * System.Threading.CancellationToken -> System.Threading.Tasks.Task<byte[]>
static member GetAttachmentAsync : Microsoft.Bot.Connector.IAttachments * string * string * System.Threading.CancellationToken -> System.Threading.Tasks.Task<System.IO.Stream>
<Extension()>
Public Function GetAttachmentAsync (operations As IAttachments, attachmentId As String, viewId As String, Optional cancellationToken As CancellationToken = Nothing) As Task(Of Byte())
<Extension()>
Public Function GetAttachmentAsync (operations As IAttachments, attachmentId As String, viewId As String, Optional cancellationToken As CancellationToken = Nothing) As Task(Of Stream)
Parameters
- operations
- IAttachments
The operations group for this extension method.
- attachmentId
- String
attachment id.
- viewId
- String
View id from attachmentInfo.
- cancellationToken
- CancellationToken
The cancellation token.
Returns
The attachment as a Stream.
Remarks
Get the named view as binary content.