michael
michael

Reputation: 110580

When to use Handler/Message to communicate in android application

I can use Intent with data stored in extras to exchange information/ communicate between 2 android activities. When should I use Handler/Message to communicate in android applications?

Thank you.

Upvotes: 0

Views: 152

Answers (1)

Peter Knego
Peter Knego

Reputation: 80340

Handlers are tied to threads, so you'd use handler when you want a task to run in another (typically UI) thread.

Upvotes: 1

Related Questions