protected async override void OnActivated(IActivatedEventArgs e) { base.OnActivated(e); ContinuationManager = new ContinuationManager(); Frame rootFrame = CreateRootFrame(); await RestoreStatusAsync(e.PreviousExecutionState); if (rootFrame.Content == null) { rootFrame.Navigate(typeof(ImageRecognizePage)); } var continuationEventArgs = e as IContinuationActivatedEventArgs; if (continuationEventArgs != null) { //Frame scenarioFrame = MainPage.Current.FindName("ScenarioFrame") as Frame; if (rootFrame != null) { // Call ContinuationManager to handle continuation activation ContinuationManager.Continue(continuationEventArgs, rootFrame); } } Window.Current.Activate(); }