[FIXED] Is there any way to create background services which will run even if the app is closed?

Issue

I am creating a Xamarin application where I used to store documents, I need to create a background service that should run continuously even if the app is closed.(for both android and iOS)

I am trying to create this background service for deleting the documents from my mobile app every 5 days.

So, adding a never-ending process for deleting documents based on days from the mobile app is a good way to do it? I need an idea of how to implement it.

I did some research I can only see MessageCenter for doing background process, but i need a way to implement a never ending background services. Is there any way?

Solution

I think that you are looking for a job that is executed periodically.

The link below provides an introduction to android jobs.
https://learn.microsoft.com/en-us/xamarin/android/platform/android-job-scheduler

Answered By – Sergi Bertran

Answer Checked By – Laura B. (Easybugfix Admin)

Leave a Reply

(*) Required, Your email will not be published