Forum Xamarin.Forms

How to do a HTTP Request every few minutes when app sleeps / user leaves app


How can I do a HTTP request every 5 minutes, if the user leaves the app / locks his phone or something similar (= if the App is not active on the screen)?
My first (probably stupid) idea was, to put a timer inside the protected override void OnSleep() method, but I am pretty sure that there is a better way.
Can somebody provide me some information / links to get started with that? Even a proper term for this problem would help me :)



  • AlessandroCaliaroAlessandroCaliaro ITMember ✭✭✭✭✭

    I dot know if XF permits this. I suppose you should create a Service in native Project

Sign In or Register to comment.