I'm trying to develop a Windows 10 app as follows:
I'm able to hit the break point in the javascript which invokes the method call to the WRC. But I'm not able to step into the code and see what's happening inside it. The reason for that is because the debugger is set to Script mode. If I set it to Native, then it will never hit the javascript code in the first place.
My problem, is that Visual Studio doesn't let me (to the best of my knowledge) to attach the source code of an external reference, so that I can put a breakpoint in it and run the debugger in native mode. Resharper has this feature, but I need a solution in Visual Studio.
Visual Studio DOES let me attach source code when I try to step into a reference from native code. I confirmed this by writing a dummy Windows 10 app using C#, and then tried to step into the invocation of the same Windows Runtime Component. When the source was not available, it asked me for the same and I was able to attach it and step through the code.
Does anyone have any ideas?
To start debugging, select F5, or choose the Debug Target button in the Standard toolbar, or choose the Start Debugging button in the Debug toolbar, or choose Debug > Start Debugging from the menu bar. The app starts and the debugger runs to the line of code where you set the breakpoint.
Begin code stepping by selecting F10 or F11. Doing so allows you to quickly find the entry point of your app. You can then continue to press step commands to navigate through the code. Run to a specific location or function, for example, by setting a breakpoint and starting your app.
C++/WinRT is an entirely standard modern C++17 language projection for Windows Runtime (WinRT) APIs, implemented as a header-file-based library, and designed to provide you with first-class access to the modern Windows API.
I had a similar problem. I have a C# Windows Runtime App which was referring the C++/CX Runtime component, and I couldn't get the break point to hit in the C++ code. The fix that worked was:
Properties
Debug
TabDebugger type
: For Application Process / Background process, select "Mixed (Managed and Native)"
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With