閱讀英文

共用方式為


IEditorOperations.ReplaceSelection Method

Replaces the text selection with the specified text.

Namespace:  Microsoft.VisualStudio.Text.Operations
Assembly:  Microsoft.VisualStudio.Text.UI (in Microsoft.VisualStudio.Text.UI.dll)

Syntax

bool ReplaceSelection(
    string text
)

Parameters

Return Value

Type: System.Boolean
true if the edit succeeded, otherwise false.

Exceptions

Exception Condition
ArgumentNullException

text is nulla null reference (Nothing in Visual Basic).

.NET Framework Security

See Also

Reference

IEditorOperations Interface

Microsoft.VisualStudio.Text.Operations Namespace