In WPF project, why a breakpoint can't stop the program? see the picture

兰树豪 381 Reputation points

User's image

Pls see the picture, this is a WPF project, set a breakpoint on inside Main ,but no use

Microsoft Technologies based on the .NET software framework.
3,323 questions
Windows Presentation Foundation
Windows Presentation Foundation
A part of the .NET Framework that provides a unified programming model for building line-of-business desktop applications on Windows.
2,660 questions
Visual Studio
Visual Studio
A family of Microsoft suites of integrated development tools for building applications for Windows, the web and mobile devices.
4,557 questions
An object-oriented and type-safe programming language that has its roots in the C family of languages and includes support for component-oriented programming.
10,164 questions
{count} votes

Accepted answer
  1. Hui Liu-MSFT 36,356 Reputation points Microsoft Vendor

    Hi,@兰树豪 . Welcome Microsoft Q&A.

    The .g.i.<lang-specific extension.> are used internally to provide various Visual Studio features including intellisense.  The files don't appear in the obj directory because they are generated in memory.

    The g.i.cs-Files are only visible in the Solution Explorer, select "Show all Files" and browse to the obj\Debug-Folder.

    You cannot debug *.g.i.cs file. (Of course, unless you have reflector plug-in integrated in your Visual Studio)

    When App.xaml is built, MSBuild generates the actual code that represents what was declared in App.xaml, storing the code in App.g.i.cs.

    User's image

    If the response is helpful, please click "Accept Answer" and upvote it.

    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.

    1 person found this answer helpful.

0 additional answers

Sort by: Most helpful