Reputation: 1555
I'm new to Xamarin platform. I'm developing an application for all three major platforms (WP,iOS,Android) using Xamarin.forms. How can I sync data with my server in the background -> I need something similar to Android Service. I want to sync the data even when the user goes to a different screen of the app. It would be great if I could continue syncing the data even when the user leaves the app.
Thank you
Upvotes: 6
Views: 5815
Reputation: 44803
This is the only solution i have found http://arteksoftware.com/backgrounding-with-xamarin-forms/
in a few words: You can't abstract background tasks in Xamarin.Forms because iOS, Android and WP works in a different way. You have to use MessagingCenter to send and receive data from specific implementations in each platform
Upvotes: 6
Reputation: 936
Have look to this article: http://developer.xamarin.com/guides/ios/application_fundamentals/backgrounding/part_3_ios_backgrounding_techniques/ios_backgrounding_with_tasks/
You could provably be interested in the Transfer Background tasks.
Regards
Upvotes: 1