1
votes

I have existing windows phone silverlight app that works fine on windows phone 8.0 and 8.1. However on windows 10, my app terminates during suspend event.
It took me a while to understand that problem in that my app takes too much time on main thread during suspending and system terminate it as stop responding. Using winrt api the solution can be accomplished by this code:

var defferal = SuspendingEventArgs.getDeferral();
await someSavingMethod();
defferal.Complete();

However I simple don't have access for that api, as my app uses only windows phone api (for running on windows phone 8.0)

Is this possible to somehow call this winrt api in my code or maybe fix suspending termination with other way on windows phone 10?

1

1 Answers

1
votes

Not possible, you have to use what the 8.0 API offers to accomplish your goal.