1. Are you ready for the Galaxy S20? Here is everything we know so far!

app starting issue

Discussion in 'Android Development' started by quentin ramecourt, Aug 25, 2021.

  1. quentin ramecourt

    Thread Starter

    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 (Text):
    1. mFamilyName = findViewById(R.id.text2);// permet de lier la balise concernée dans le XML
    2. mButtonSubmit.setEnabled(false);//désactive le bouton par défaut
    3. mFamilyName.addTextChangedListener(new TextWatcher() {
    4.     [USER=1021285]@override[/USER]
    5.     public void beforeTextChanged(CharSequence charSequence, int i, int i1, int i2) {
    6.  
    7.     }
    8.  
    9.     [USER=1021285]@override[/USER]
    10.     public void onTextChanged(CharSequence charSequence, int i, int i1, int i2) {
    11.  
    12.     }
    13.  
    14.     [USER=1021285]@override[/USER]
    15.     public void afterTextChanged(Editable editable) {
    16.         mButtonSubmit.setEnabled(!editable.toString().isEmpty());
    17.     }
    18.  
    19. });
    20. mButtonSubmit.setOnClickListener(new View.OnClickListener() {
    21.     [USER=1021285]@override[/USER]
    22.     public void onClick(View view) {
    23.  
    so if anyone has a solution, please help
     


    #1 quentin ramecourt, Aug 25, 2021
    Last edited by a moderator: Aug 25, 2021

    1. Download the Forums for Android™ app!


      Download

       
  2. Unforgiven

    Unforgiven ...eschew obfuscation...
    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!! :)
     
    olbriar likes this.
Loading...
Similar Threads - app starting issue
  1. farter
    Replies:
    1
    Views:
    785
  2. kumaranil13k
    Replies:
    1
    Views:
    434
  3. tapio
    Replies:
    5
    Views:
    781
  4. corpID
    Replies:
    0
    Views:
    534
  5. Saza
    Replies:
    0
    Views:
    579
  6. Billybronco
    Replies:
    4
    Views:
    657
  7. Samsung
    Replies:
    1
    Views:
    379
  8. Emoto
    Replies:
    2
    Views:
    1,959
  9. Peter22
    Replies:
    2
    Views:
    826

Share This Page

Loading...