Thanks for the guidance.
I will go for the broadcast-receiver mechanism, that is technically better.
I will stop the service when we loose internet connection and start it when
internet is back on
--
You received this message because you are subscribed to the Google
Groups Android Developers
Hi all,
I have a very simple app, which has 1 screen with few buttons. It will start a
service which will pay music using mediaplayer.
Now, sometimes if I go in no internet coverage area or move between 3g and
wifi, the player stops and service completes (does its onDestroy).
I am thinking of
It sounds like you are trying to fix the symptom of a problem rather than
address the actual issue. The real question should be Why does my service
get destroyed?
Have you looked into why your service gets destroyed? What kind of service
are you using (hopefully not IntentService)?
On Fri, Apr
On Fri, Apr 17, 2015 at 8:50 AM, NewToAndroid rahulra...@gmail.com wrote:
I have a very simple app, which has 1 screen with few buttons. It will
start a service which will pay music using mediaplayer.
Now, sometimes if I go in no internet coverage area or move between 3g and
wifi, the player
*When there is no internet connectivity, the mediaplayer assumes, the mp3
it was playing is finished and performs onComplete method. I had put
stopself in onCompletion, so the service is stopping.*
*Now, somewhere I would like to have this code that, if the mediaplayer has
completed itself
Yes. It might be the case that I am not going to the root cause.
I have a main activity, which starts a service. The service creates a
MediaPlayer object and plays a MP3. This MP3 is not a mp3 file, but it is
the live stream which is played over internet.
When there is no internet
6 matches
Mail list logo