android.view.ViewRootImpl$CalledFromWrongThreadException: Only the original thread that created a view hierarchy can touch its views.

  1. 0

    Thread starts before client connects

    Stack Overflow | 2 months ago | Lambros Hitiris
    android.view.ViewRootImpl$CalledFromWrongThreadException: Only the original thread that created a view hierarchy can touch its views.
  2. 0

    udp android server over wifi

    Stack Overflow | 3 years ago | N.B
    android.view.ViewRootImpl$CalledFromWrongThreadException: Only the original thread that created a view hierarchy can touch its views.
  3. 0

    buttonConnectOnClickListener, FATAL EXCEPTION: AsyncTask #1

    Stack Overflow | 4 years ago | user1810991
    java.lang.RuntimeException: An error occured while executing doInBackground()
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    Android program crashes when writing to TextView in loop

    Stack Overflow | 3 years ago | MrUser
    android.view.ViewRootImpl$CalledFromWrongThreadException: Only the original thread that created a view hierarchy can touch its views.
  6. 0

    How to deal with AsyncTask with UI thread in the do while situation

    Stack Overflow | 2 years ago | user3799770
    android.view.ViewRootImpl$CalledFromWrongThreadException: Only the original thread that created a view hierarchy can touch its views.

  1. asvid 1 times, last 6 months ago
Not finding the right solution?
Take a tour to get the most out of Samebug.

Tired of useless tips?

Automated exception search integrated into your IDE

Root Cause Analysis

  1. android.view.ViewRootImpl$CalledFromWrongThreadException

    Only the original thread that created a view hierarchy can touch its views.

    at android.view.ViewRootImpl.checkThread()
  2. Android Platform
    TextView.append
    1. android.view.ViewRootImpl.checkThread(ViewRootImpl.java:6363)
    2. android.view.ViewRootImpl.invalidateChildInParent(ViewRootImpl.java:909)
    3. android.view.ViewGroup.invalidateChild(ViewGroup.java:4691)
    4. android.view.View.invalidateInternal(View.java:11810)
    5. android.view.View.invalidate(View.java:11774)
    6. android.view.View.invalidate(View.java:11758)
    7. android.widget.TextView.updateAfterEdit(TextView.java:7705)
    8. android.widget.TextView.handleTextChanged(TextView.java:7728)
    9. android.widget.TextView$ChangeWatcher.onTextChanged(TextView.java:9475)
    10. android.text.SpannableStringBuilder.sendTextChanged(SpannableStringBuilder.java:964)
    11. android.text.SpannableStringBuilder.replace(SpannableStringBuilder.java:515)
    12. android.text.SpannableStringBuilder.append(SpannableStringBuilder.java:272)
    13. android.text.SpannableStringBuilder.append(SpannableStringBuilder.java:33)
    14. android.widget.TextView.append(TextView.java:3627)
    15. android.widget.TextView.append(TextView.java:3614)
    15 frames
  3. com.example.seth
    MainActivity$ClientThread.run
    1. com.example.seth.chat4all.MainActivity$ClientThread.run(MainActivity.java:127)
    1 frame
  4. Java RT
    Thread.run
    1. java.lang.Thread.run(Thread.java:818)
    1 frame