Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to debug Windows Phone 8.1 app which was started by protocol association?

My app needs a protocol activation, I implemented it by following official guideline.

Check activation Kind at OnActivated and initialize a new frame and window if protocol detected.

When app starts and attaches to debugger by F5 I see a main page, the next I press back button and click to link at email. The app starts correctly and show me a required page.

But the app will show splash screen and close itself if I kill app by process manager before click a link.

So I should debug app to localize bug, but the debugger detaches when the app has been killed.

Please help me to find a way to debug it!

like image 611
Viacheslav Smityukh Avatar asked Mar 16 '23 07:03

Viacheslav Smityukh


1 Answers

To debug such scenarios, there is a special option in Visual Studio.

  1. In Solutions Explorer, right click your project and select Properties.
  2. In Debug tab, check the "Do not launch, but debug my code when it starts" checkbox.

enter image description here

Now debug by pressing F5. The app will deploy and debugger will attach, but the app will not launch. Now click the mail link. At this point your app should start due to protocol activation and debugger will work as expected.

like image 130
Abhishek Avatar answered Apr 30 '23 23:04

Abhishek