Re: conditional directives

"Bart De Smet [MVP]" <[email protected]> Wed, 14 Mar 2007 19:59:22 +0100
Newsgroups gmane.comp.windows.devel.dotnet.cx
Message-ID <006201c7666a$e0ff1b10$a2fd5130$@net>
Hi Peter,



You can get rid of the #define precompilation statements by defining the
conditional compilation symbols through the project properties, tab Build.
Basically, this feeds the underlying compiler with additional
to-be-#define-d symbols (like csc /define:<symbols> or csc /d:<symbols>). If
you want to create additional configuration (see drop-down list under
Build), you can go to the menu Build, Configuration Manager.



Hope this helps,



-Bart



-----Original Message-----
From: Discussion relating to the specifics of the C# and Managed C++
languages [mailto:[email protected]] On Behalf Of Peter Osucha
Sent: woensdag 14 maart 2007 18:43
To: [email protected]
Subject: [DOTNET-CX] conditional directives



I haven't had much use for these in the past (or better yet, I didn't

understand how they could be used so I didn't use them).







Anyway, I have a need with my current development to limit some

functionality while running from the IDE.  I figured I could use

'#if..." to do such a conditional thing.  But there are a few things I

don't understand about doing this.  If I have these #define IDE commands

all over my files, before a release build, I'd have to remove them,

correct (which seems like a pain)?  Is there a better way to

conditionally skip some things while running from the IDE?







Peter





===================================

This list is hosted by DevelopMentor.  http://www.develop.com



View archives and manage your subscription(s) at http://discuss.develop.com


===================================
This list is hosted by DevelopMentorĀ®  http://www.develop.com

View archives and manage your subscription(s) at http://discuss.develop.com