I am developing an app. The basic concept of the app is that I have to keep few video playing continuously. The list of videos i.e playist is maintained by webservice. The playlist has dates on which date which playlist is to be played. My problem is how to check the date and load playist accordingly? The videos from proper playlist should keep on playing. So do I need to keep a service in background which checks the date each day or what do i need to do?
Asked
Active
Viewed 144 times
2 Answers
0
Use a specific function which gets called by itself after your required time and check the time and date condition if matches do the task.. if u wish a delay/ recursive call function can be provided..

Abhijeet
- 87
- 3
-
But where to call this specific function? Do I need to start a service or what shall i do? – newBie May 29 '13 at 04:19
-
how do u start your service... suppose " xyz();" put this call in that specific iterative function which will call itself after specific interval of time, check the condition and execute the task.. – Abhijeet May 29 '13 at 05:38
0
Handler handler = new Handler();
handler.postDelayed(new Runnable()
{
public void run()
{
webservicecall();
}
}, 2000); // 2sec
this is an eg. to set time interval u can use it logically as u want

Abhijeet
- 87
- 3
-
How till I stop the thread as my app exits ? Can I handle this by handler or do i need to use service? I am pretty confused Please help... – newBie May 30 '13 at 07:28