How do you get the binding to debug?

Lloyd Sheen 1,481 Reputation points
2024-02-01T16:21:50.93+00:00

I am now in the VS/Maui screwup that does not debug. I get an error message but since it should stop when there is an error and it does not I am at a loss. I get the "System.Reflection.TargetInvocationException: 'Exception has been thrown by the target of an invocation.'" which is the most useless error that VS has ever shown as it does not have anything to help isolate the error as it does not show where the error occurs. There has to be some debug option that I do not have set as there is no way a company can release a product for debugging that does not debug. I am using dot.net 7.0 and Microsoft Visual Studio Community 2022 (64-bit) - Current Version 17.7.7. I know there is a later version of VS but that version does not create usable "release" versions of the app.

.NET MAUI
.NET MAUI
A Microsoft open-source framework for building native device applications spanning mobile, tablet, and desktop.
3,701 questions
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. Bruce (SqlWork.com) 68,081 Reputation points
    2024-02-01T22:13:44.18+00:00

    debugging Maui is complex, because VS uses the native debugger remotely. the debug image is mix of the compiled dotnet code, native code, and native libraries. if you need lower level debugging, just use the native debugger directly, rather than VS remote execution of the debugger. as .net 7 support ends this November, you probably should upgrade.

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.