SetDataAsync Method
Places a data object on the clipboard. The data object is responsible for providing supported formats and data upon request.
Definition
Namespace: Avalonia.Input.Platform
Assembly: Avalonia.Base (in Avalonia.Base.dll)
- C#
- VB
- F#
Task SetDataAsync(
IAsyncDataTransfer? dataTransfer
)
Function SetDataAsync (
dataTransfer As IAsyncDataTransfer
) As Task
abstract SetDataAsync :
dataTransfer : IAsyncDataTransfer -> Task
Parameters
- IAsyncDataTransfer
- The data object to set on the clipboard.
Return Value
TaskRemarks
If dataTransfer is null, nothing will get placed on the clipboard and this method will be equivalent to ClearAsync().
The IAsyncDataTransfer must NOT be disposed by the caller after this call. The clipboard will dispose of it automatically when it becomes unused.