Since I update to IOS 11.03 in my Iphone 6, I can't save properties with Xamarin.Forms.Application.Current.SavePropertiesAsync(), I use this metod in DidEnterBackground event in IOS Project and in OnSleep() event in PCL Project. Any idea??
protected override async void OnSleep() { await Current.SavePropertiesAsync(); base.OnSleep(); } public override async void DidEnterBackground(UIApplication application) { Messaging.SharedInstance.Disconnect(); await Xamarin.Forms.Application.Current.SavePropertiesAsync(); Console.WriteLine("Disconnected from FCM"); }
Posts
Please help me!
@Ganturock Just a guess since I don't really know what SavePropertiesAsync() does but you shouldn't try to execute any long running tasks in DidEnterBackground unless you setup a background task.
https://developer.apple.com/library/content/documentation/iPhone/Conceptual/iPhoneOSProgrammingGuide/BackgroundExecution/BackgroundExecution.html