In my web.config I have the standard element;
<compilation debug="true" defaultLanguage="c#">
I know I could use [Conditional("DEBUG")] on methods, or use some pre-compiler if statement like #if DEBUG, but what I am looking for is the built-in .NET framework setting that lets me know if the setting for debug in the compilation section.
I've seen it done before but can't find it or remember it.
Duplicate - Programmatically access the <compilation />
section of a web.config?
-
HttpContext.Current.IsDebuggingEnabled (posted by Jason Diamond) was what I was looking for.
Thanks for your help Marc!
Marc Gravell : You might want to close the question, then. And maybe chuck Jason a +1 ;-pDead account : How do I close a question? (Sorry - bit of a noob)From Dead account
0 comments:
Post a Comment