• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 267
  • Last Modified:

Quick one - visual studio - Release version should hide extra debug info

Hi all,
I have a Windows Application and we have a very simple interface.
We have a lot of extra info that we display when we are testing the solution.

At the moment we just use a boolean in the code to say whether to display extra panels or not.
I would like to take this out of the code and have it as an option somewhere.
I have seen that you can have debug versions and release versions of applications.
So i would simply like to set a bool flag to false if I compile a release to turn of all the extra info.

Any ideas?
Thanks
Dave
0
CoreSupport
Asked:
CoreSupport
1 Solution
 
AgariciCommented:
in your constructor or main or whereever you init that boolean put sometrhing like this:


#ifndef DEBUG
yourBoolean = false;
#else
yourBoolean = true;
#endif

hth,
A.
0
 
wishguitarCommented:
Try

#if DEBUG
      showPanels = true;
#else
      showPanels = false;
#endif
0

Featured Post

Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now