Partager via


ITextDocumentSnapshot.GetLineNumberFromPosition(Int32) Method

Definition

Gets the number of the line that contains the character at the specified position.

public int GetLineNumberFromPosition (int position);
abstract member GetLineNumberFromPosition : int -> int
Public Function GetLineNumberFromPosition (position As Integer) As Integer

Parameters

position
Int32

Returns

The line number of the line in which position lies.

Exceptions

position is less than zero or greater than Length/>.

Applies to