0

I create an android application with android studio and I wish to trigger a function in the interval of 1 hours. When the function is trigger I need to call a asp file by URL and check the database with this asp file. If is there any available record return from asp file, then I trigger the notification, if there is no record exists, my application do nothing.

Letter that I bold in above is the function I wish to achieve. Anyone know how to achieve this in a simple method ??

Please do let me know if there is anything unclear.

Thanks !!

  • have you check my answer on this [SO](https://stackoverflow.com/questions/50732213/optimal-way-of-doing-background-opertion-in-android/50732277#50732277) ? – Sagar Jun 08 '18 at 02:25
  • Thanks, but I found it out. I used Alarm Manager to help me done the job and it run smoothly. –  Jun 08 '18 at 02:34
  • Have you tested it on Android O with doze mode restriction? – Sagar Jun 08 '18 at 02:37
  • Nope, not yet. Still under progress. Thanks for your information ! –  Jun 08 '18 at 02:51
  • Standard Alarms won't fire during Doze mode and also you cannot start background Services from Android O. It will give `IllegalStateException` and could crash your app – Sagar Jun 08 '18 at 02:53

0 Answers0