Skip to main content

TryGetDataAsync Method

Retrieves data from the clipboard.

Definition

Namespace: Avalonia.Input.Platform
Assembly: Avalonia.Base (in Avalonia.Base.dll)

Task<IAsyncDataTransfer?> TryGetDataAsync()
View Source

Return Value

Task(IAsyncDataTransfer)

Remarks

The returned IAsyncDataTransfer MUST be disposed by the caller.

Avoid storing the returned IAsyncDataTransfer instance for a long time: use it, then dispose it as soon as possible.

See Also

Reference

IClipboard Interface
Avalonia.Input.Platform Namespace