Skip to content

Instantly share code, notes, and snippets.

@chris-piekarski
Created May 2, 2013 21:17
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save chris-piekarski/5505537 to your computer and use it in GitHub Desktop.
Save chris-piekarski/5505537 to your computer and use it in GitHub Desktop.
Android Views & CalledFromWrongThreadException
#CalledFromWrongThreadException
#Views can only be executed on by the thread that created them. If your in a different thread you have to use
#the runOnUiThread method.
runOnUiThread(new Runnable() {
public void run() {
//stuff that updates ui
}
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment