I have scenario where I allow only 1 character in edittext. so in onTextChanged I have checked if one letter is input, then I switch the focus to next edittext
<EditText
android:id="@+id/etpinPassword1"
style="@style/Edittext_with_weight"
android:imeOptions="actionNext"
android:inputType="number"
android:maxLength="1" />
and here my is textWatcher code:
onTextChanged :- >
if (isValueEntered(charSequence)) {
etpinPassword2.requestFocus();
etpinPassword2.setEnabled(true);
appendPassword(charSequence);
}
private boolean isValueEntered(CharSequence charSequence) {
return charSequence.length() > 0;
}
Everything is working fine, except when I come back to an already filled edittext, onTextChanged is never called. I want to call it again so that I can switch the focus to next edittext if first one is already full.