Docsv3.20.2
Back to API Reference
Struct

CapturedSelection

sealed

A field's selection captured for a replacement that arrives later — from a web request or another app. Replace lands only while the field still holds the text the capture was taken from.

public bool Replace()

Replaces the captured selection with text as a plain-text paste does — input filters, length limits and one undo step included — and reports whether it did: false once the field is destroyed or its text has changed since the capture. An empty text deletes the selection.