TextView.OnTextChanged Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Overloads
OnTextChanged(ICharSequence, Int32, Int32, Int32) |
This method is called when the text is changed, in case any subclasses would like to know. |
OnTextChanged(String, Int32, Int32, Int32) |
This method is called when the text is changed, in case any subclasses would like to know. |
OnTextChanged(ICharSequence, Int32, Int32, Int32)
This method is called when the text is changed, in case any subclasses would like to know.
[Android.Runtime.Register("onTextChanged", "(Ljava/lang/CharSequence;III)V", "GetOnTextChanged_Ljava_lang_CharSequence_IIIHandler")]
protected virtual void OnTextChanged (Java.Lang.ICharSequence? text, int start, int lengthBefore, int lengthAfter);
[<Android.Runtime.Register("onTextChanged", "(Ljava/lang/CharSequence;III)V", "GetOnTextChanged_Ljava_lang_CharSequence_IIIHandler")>]
abstract member OnTextChanged : Java.Lang.ICharSequence * int * int * int -> unit
override this.OnTextChanged : Java.Lang.ICharSequence * int * int * int -> unit
Parameters
- text
- ICharSequence
The text the TextView is displaying
- start
- Int32
The offset of the start of the range of the text that was modified
- lengthBefore
- Int32
The length of the former text that has been replaced
- lengthAfter
- Int32
The length of the replacement modified text
- Attributes
Remarks
This method is called when the text is changed, in case any subclasses would like to know.
Within text
, the lengthAfter
characters beginning at start
have just replaced old text that had length lengthBefore
. It is an error to attempt to make changes to text
from this callback.
Java documentation for android.widget.TextView.onTextChanged(java.lang.CharSequence, int, int, int)
.
Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.
Applies to
OnTextChanged(String, Int32, Int32, Int32)
This method is called when the text is changed, in case any subclasses would like to know.
protected void OnTextChanged (string? text, int start, int lengthBefore, int lengthAfter);
member this.OnTextChanged : string * int * int * int -> unit
Parameters
- text
- String
The text the TextView is displaying
- start
- Int32
The offset of the start of the range of the text that was modified
- lengthBefore
- Int32
The length of the former text that has been replaced
- lengthAfter
- Int32
The length of the replacement modified text
Remarks
This method is called when the text is changed, in case any subclasses would like to know.
Within text
, the lengthAfter
characters beginning at start
have just replaced old text that had length lengthBefore
. It is an error to attempt to make changes to text
from this callback.
Java documentation for android.widget.TextView.onTextChanged(java.lang.CharSequence, int, int, int)
.
Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.