brake point never hit

mastiSoft
mastiSoft used Ask the Experts™
on
Hi, I like to use  a brake point for debug.  Never had a problem with it until I started to work on VS 2017 (Professional ).
Now no matter where I put a brake point it is never hit.
Do you have any idea how to fix this?
Comment
Watch Question

Do more with

Expert Office
EXPERT OFFICE® is a registered trademark of EXPERTS EXCHANGE®
AndyAinscowFreelance programmer / Consultant

Commented:
Are you actually running the code you have in the editor.  Maybe the time stamps have got corrupted somehow.

You could try performing a rebuild all and seeing if that helps.
Most Valuable Expert 2018
Distinguished Expert 2018

Commented:
Clean the solution, rebuild the solution and make sure you have the Debug configuration selected. If you have Release selected, you won't hit the breakpoints.
Ryan ChongSoftware Team Lead

Commented:
Now no matter where I put a brake point it is never hit.

try do a step debugging (F11) and see if it hits that break point?
Exploring ASP.NET Core: Fundamentals

Learn to build web apps and services, IoT apps, and mobile backends by covering the fundamentals of ASP.NET Core and  exploring the core foundations for app libraries.

Author

Commented:
I have Active(Debug) configuration and using F11 didn't make any difference.
Chinmay PatelChief Technology Ninja
Distinguished Expert 2018

Commented:
1. It sounds like a hack but please clear all existing break points and then add a new one and see if it works. This worked for me in one of the app - I never encountered it afterwards so I am not sure.
2. Take a screen shot of Tools -> Options -> Debugging -> General and post it here.
3. What value do you see in Project Properties -> Advanced -> Debugging?
AndyAinscowFreelance programmer / Consultant

Commented:
Did you do a complete rebuild as I suggested.  (That is nothing to do with the F11 key).

Author

Commented:
Yes I complete rebuild as you suggested Andy, but still nothing happens.

Author

Commented:
Hi Chinmay.
Please find attached here screen shots of Options and Project Properties. I hope you find something.
Options.PNG
ProjectPropert.PNG
ProjectPropert2.PNG
Chief Technology Ninja
Distinguished Expert 2018
Commented:
Please uncheck Optimize Code flag. It will optimize the code and that will rid of the debugging data from the generated executable i.e. No Debugging.

Author

Commented:
Thank you Mr. Chinmay ). You always help me.
Chinmay PatelChief Technology Ninja
Distinguished Expert 2018

Commented:
Glad I could help.

Do more with

Expert Office
Submit tech questions to Ask the Experts™ at any time to receive solutions, advice, and new ideas from leading industry professionals.

Start 7-Day Free Trial