Condividi tramite


IVsTextView.ClearSelection Method

Clears the current selection.

Namespace:  Microsoft.VisualStudio.TextManager.Interop
Assembly:  Microsoft.VisualStudio.TextManager.Interop (in Microsoft.VisualStudio.TextManager.Interop.dll)

Syntax

'Dichiarazione
Function ClearSelection ( _
    fMoveToAnchor As Integer _
) As Integer
'Utilizzo
Dim instance As IVsTextView
Dim fMoveToAnchor As Integer
Dim returnValue As Integer

returnValue = instance.ClearSelection(fMoveToAnchor)
int ClearSelection(
    int fMoveToAnchor
)
int ClearSelection(
    [InAttribute] int fMoveToAnchor
)
abstract ClearSelection : 
        fMoveToAnchor:int -> int 
function ClearSelection(
    fMoveToAnchor : int
) : int

Parameters

  • fMoveToAnchor
    Type: System.Int32
    [in] If true, the cursor is placed at the anchor after the current selection is cleared. If false, then the cursor is not moved.

Return Value

Type: System.Int32
If the method succeeds, it returns S_OK. If it fails, it returns an error code.

Remarks

COM Signature

From textmgr.idl:

HRESULT IVsTextView::ClearSelection(
   [in] BOOL fMoveToAnchor
);

The anchor position is the first location that the user selected with the mouse.

.NET Framework Security

See Also

Reference

IVsTextView Interface

IVsTextView Members

Microsoft.VisualStudio.TextManager.Interop Namespace