[]
        
(Showing Draft Content)

GrapeCity.Wpf.SpreadSheet.CellType.Editors.GcTextBox.GetLineIndexFromCharacterIndex

GetLineIndexFromCharacterIndex Method

GetLineIndexFromCharacterIndex(int)

Returns the zero-based line index for the line that contains the specified character index.

Declaration
public int GetLineIndexFromCharacterIndex(int charIndex)
Public Function GetLineIndexFromCharacterIndex(charIndex As Integer) As Integer
Parameters
Type Name Description
int charIndex

The zero-based character index for which to retrieve the associated line index.

Returns
Type Description
int

The zero-based index for the line that contains the specified character index.

Exceptions
Type Condition
ArgumentOutOfRangeException

charIndex is negative or greater than the length of the content.