Assign the constant to a variable and display the variable in your debugger.
Constants are replaced by their values upon compilation.
Main Topics
Browse All TopicsI am debugging an application that has a bunch of constants in an include file called stairs.h . In the debugger I cannot see the values of the constants. I have an if statement with multiple conditions that is coming out False and would like to see the value of the constant being referred to.
This Question has been solved and asker verified All Experts Exchange premium technology solutions are available to subscription members.
Experts Exchange has been collecting answers to technology questions since 1996…3 million and counting! If you have a question, chances are we already have your answer.
If you can't find the exact answer you're looking for, ask our exclusive community of 50,000 experts. You’ll get a personalized answer from a trusted professional.
Thousands of free tech tips, tricks, how-to’s and tutorials are available in our peer reviewed articles section. See for yourself how smart our experts are, no login required.
Access the answers to your technology questions today.
30-day free trial. Register in 60 seconds.
Members of the expert community talk about why the experience at Experts Exchange is different than what you will find anywhere else.

Try it out and discover for yourself.
30-day free trial. Register in 60 seconds.
Join the community of experts here and help other tech pros by answering question in your area of expertise. You can earn FREE access to all Experts Exchange's premium features and resources.
CaptainCyril is correct, constants do not exist when the application is ran, they are a simple way of maintaining values in your code that you can easily change at one point in your program. They are a development environment 'perk' really. When you compile the code, the constants are replaced in your code with the value that is allocated to them, therefore the debugger will not see them as a variable.
All points to CaptainCyril.
Ant
Business Accounts
Answer for Membership
by: CarlWarnerPosted on 2005-11-14 at 13:31:34ID: 15291215
Not in my debugger.
I tried a value that was equal to a minimum fee of ($)50. I couldn't get it evaluated to save my life.