Asp net break point set but not firing in visual studio 2019


ASP.NET is a popular programming language used for developing web applications. It provides a powerful for building dynamic and interactive websites. However, like any programming language, developers may encounter issues and challenges while working with ASP.NET. One problem that developers face is the breakpoint not firing in Visual Studio 2019.

Understanding the

When debugging an ASP.NET application in Visual Studio 2019, breakpoints are essential for pausing the execution of the code and inspecting variables and objects. However, there are instances where breakpoints may not be firing, causing frustration and hindering the debugging process.

Possible Causes

There can be several reasons why breakpoints are not firing in Visual Studio 2019. Let's explore some of the common causes:

1. Optimization Settings

Visual Studio has optimization settings that can affect the behavior of breakpoints. If the optimization settings are , the compiler may optimize the code and skip the execution of lines, including breakpoints. To check the optimization settings, follow these steps:

1. Open Visual Studio 2019.
2. Go to Tools > Options.
3. Expand the "Debugging" tab.
4. Select "General".
5. Ensure that the "Suppress JIT optimization on module load" option is unchecked.

2. Debug Configuration

Make sure that the project is configured for debugging. Sometimes, developers accidentally switch the project configuration to “” mode, disables debugging features. To switch back to the debug configuration, follow these steps:

1. Right-click on the project in the Solution Explorer.
2. Select "Properties".
3. Go to the "Build" tab.
4. Ensure that the "Configuration" dropdown is set to "Debug".

3. Files

Symbol files (.pdb) debugging information that allows Visual Studio to map the compiled code to the original source code. If the symbol files are missing or not up-to-date, breakpoints may not work correctly. To ensure that symbol files are generated and loaded, follow these steps:

1. Right-click on the project in the Solution Explorer.
2. Select "Properties".
3. Go to the "Build" tab.
4. Ensure that the "Advanced" button is clicked.
5. Check the "Debug Info" dropdown and select "Full" or "pdb-only".
6. Rebuild the project to generate the symbol files.


Debugging is an essential part of the process, and breakpoints play a crucial role in identifying and fixing issues in ASP.NET applications. If breakpoints are not firing in Visual Studio 2019, it can be frustrating, but by checking the optimization settings, project configuration, and symbol files, you can resolve the issue and continue debugging effectively.

Rate this post

Leave a Reply

Your email address will not be published. Required fields are marked *

Table of Contents