Skip to main content

SetTextAsync Method

Places a text on the clipboard.

Definition​

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

Task SetTextAsync(
string? text
)
View Source

Parameters​

  String
The text value to set.

Return Value​

Task

Remarks​

By calling this method, the clipboard will get cleared of any possible previous data.

If text is null or empty, nothing will get placed on the clipboard and this method will be equivalent to ClearAsync().

See Also​

Reference​

IClipboard Interface
Avalonia.Input.Platform Namespace