• After 15+ years, we've made a big change: Android Forums is now Early Bird Club. Learn more here.

app starting issue

hello everyone. so my issue is the following: i try to create a quizz following a tutorial, but my function meant to detect a typing on the emulator and make a button reappear make my application crash continuously, thus making it impossible to start, here is the code:
Code:
mFamilyName = findViewById(R.id.text2);// permet de lier la balise concernée dans le XML
mButtonSubmit.setEnabled(false);//désactive le bouton par défaut
mFamilyName.addTextChangedListener(new TextWatcher() {
    [USER=1021285]@override[/USER]
    public void beforeTextChanged(CharSequence charSequence, int i, int i1, int i2) {

    }

    [USER=1021285]@override[/USER]
    public void onTextChanged(CharSequence charSequence, int i, int i1, int i2) {

    }

    [USER=1021285]@override[/USER]
    public void afterTextChanged(Editable editable) {
        mButtonSubmit.setEnabled(!editable.toString().isEmpty());
    }

});
mButtonSubmit.setOnClickListener(new View.OnClickListener() {
    [USER=1021285]@override[/USER]
    public void onClick(View view) {
so if anyone has a solution, please help
 
Last edited by a moderator:
Welcome to Android Forums. I moved your thread to the development area in hopes of getting better visibility to the folks that may be able to help. I also added code tags to your post for readability. Good luck!! :)
 
Back
Top Bottom