IVsTextView.SetCaretPos Method

Sets the coordinates of the end point of a selection.

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

int SetCaretPos(
	int iLine,
	int iColumn
)

Parameters

iLine
Type: System.Int32

[in] Line containing the caret position.

iColumn
Type: System.Int32

[in] Column identifying the caret position. Viewcol coordinates may include virtual space.

Return Value

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

COM Signature

From textmgr.idl:

HRESULT IVsTextView::SetCaretPos(
   [in] long iLine,
   [in] ViewCol iColumn
);

Was this page helpful?
(1500 characters remaining)
Thank you for your feedback
Show:
© 2014 Microsoft