Rickstar
Rickstar

Reputation: 6199

Dialog box pops-up from background service Android

I wanted to know if its possable before I start my project.

I wanted my app running in the background and when i get a message through a dialog box will pop-up, Just like how the alarm app works on the android you set the alarm and when the alarm sounds it show you a picture of the alarm and you can snooze or stop it.

Is this possable to have this sort of alert in my app?

Upvotes: 2

Views: 803

Answers (1)

saiful103a
saiful103a

Reputation: 1129

Yes it is very much possible. Create a broadcastreciever of your own and register it via android manifest file. Have your service send a broadcast to your broadcastreciever which will execute onRecieve method.

In your onRecieve you can do whatever you want. :)

Upvotes: 5

Related Questions