Spread WPF 18
GrapeCity.Wpf.SpreadSheet.CellType.Editors Namespace / GcTextBox Class / GetCharacterIndexFromPoint Method
A point in GcTextBox coordinate-space for which to return an insertion index.
true to return the nearest insertion index if there is no character at the specified point; false to return –1 if there is no character at the specified point.


In This Topic
    GetCharacterIndexFromPoint Method
    In This Topic
    Returns the zero-based insertion index for the specified point.
    Syntax
    'Declaration
     
    Public Function GetCharacterIndexFromPoint( _
       ByVal point As Point, _
       ByVal snapToText As Boolean _
    ) As Integer
    'Usage
     
    Dim instance As GcTextBox
    Dim point As Point
    Dim snapToText As Boolean
    Dim value As Integer
     
    value = instance.GetCharacterIndexFromPoint(point, snapToText)
    public int GetCharacterIndexFromPoint( 
       Point point,
       bool snapToText
    )

    Parameters

    point
    A point in GcTextBox coordinate-space for which to return an insertion index.
    snapToText
    true to return the nearest insertion index if there is no character at the specified point; false to return –1 if there is no character at the specified point.

    Return Value

    The insertion index for the specified point, or –1 if no valid insertion index can be found.
    See Also