1
vote
1answer
16 views

I do not how stop my service

I have a problema with my service. I have 3 button, the first one call service in order to get numbers at randon and show them in a textbox every 10 second, the second button call service in order to ...
1
vote
0answers
17 views

start activity B from service, and main activity Aalways be called first

I have a launcher activity called MainActivity. MainActivity will start KeyGuardService, and KeyGuardService regist a ScreenOFF receiver, and then in onReceive will start LockScreenActivity use ...
0
votes
2answers
15 views

Android: Thread still Running forever although the Service already destroy

I have try build a android application that use a thread inside a service, the service and the thread run with well, but when i stop and destroy the service, the thread still live, so when i run again ...
1
vote
4answers
22 views

How to stop Service from another activity in Android?

I have 2 activities, A & B. The Service starts in B with such code: startService(new Intent(this, PlayerService.class)); Intent connectionIntent = new Intent(this, ...
0
votes
1answer
15 views

Need advices for Activity and Service behavior

My question is rather theoric, in fact I already saw examples on how to bind or how to start an Activity with a service but I still don't get one thing: I wrote a Service that is bounded to an ...
0
votes
0answers
8 views

Service started by PhoneStateListener is killed before finished

I have a question about service behavior when started by a PhoneStateListener. My client wants a security software to track stolen devices. The feature I'm writing take pictures when SEND button is ...
0
votes
1answer
18 views

Updating Activity with Latitude/Longitude values returned from a Service

I'm trying to write a simple app that updates the MainActivity with the Lat/Lng values returned by the service. But it always returns the null value. I have added permissions and added ...
0
votes
1answer
22 views

Android Service onStartCommand() fired when the app force closes

I start a Servicefrom within an Activity and then I bind the Activity to it. If I try to force close the app from the Task Manager, the Service onStartCommand() method is called and a ...
2
votes
1answer
23 views

How to call some Service methods from a ListView Adapter?

I have a ListView with a list of downloads. Each item has a Button to start/pause/stop a download. All download-related processes are performed into a Service. How can I call my download Service ...
0
votes
1answer
26 views

How to initiate a timer every time an incoming call is received?

I want a timer to start when an incoming call is received and stop when the call is picked up or is ended by the the caller. To put it simply, I want the ring time. Yes, the time the phone is ...
0
votes
0answers
17 views

How to wrap third party library as android service?

So I have a library that drives external devices over bluetooth or wifi. The library was written by another party and I cant really change it. There will be multiple android applications controlling ...
0
votes
1answer
15 views

Restarting a service on Network Change Android

I know it's not possible to keep the same socket across network changes, but what is the easiest way to restart a service after a network change? I assume the best practice is to listen for a ...
0
votes
1answer
5 views

(Reflective) Method call delivers same old results until app is force stopped and restarted (…is there something automatically cached somehow?)

I have a strange problem and hope that someone of you has an idea what happens here. My app structure is as follows: I have a main service which registers a broadcast receiver and listens to ...
1
vote
1answer
53 views

getExtra crashing the app in Service

I search a lot and I tried several ways but I couldn't find anything that avoid my error. I'm working on app for my learning, where is an String in my MainActivity and then I call it in my Service. I ...
0
votes
1answer
447 views

How to start a service in android when the time is 7pm on the device

i am building an application in which i need to start a service when the time is 7pm. is there any way to do so please help.

1 2 3 4 5 227
15 30 50 per page