PC Review


Reply
Thread Tools Rate Thread

Debug in web.config

 
 
muriwai
Guest
Posts: n/a
 
      28th May 2007
Hi,

I have <compilation debug="true"> in my web.config. The trouble is that I
have to manually change this to "false" every time I publish the website. I
tried moving this to global machine.config and web.config on the development
machine, but then VS 2005 complains that there's no Debug in web.config and
asks to modify the file. When I remove the compilation section completely
from local web.config, VS 2005 adds a new one. This is a big annoyance for
me, or am I missing something?

Thanks

C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\CONFIG\machine.config
<configuration>
<system.web>
<compilation debug="true" />

C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\CONFIG\web.config
<configuration>
<system.web>
<compilation debug="true">
...



--



 
Reply With Quote
 
 
 
 
Walter Wang [MSFT]
Guest
Posts: n/a
 
      29th May 2007
Hi muriwai,

I believe following article can help answer your question:

#K. Scott Allen : Debug and Release Builds in ASP.NET 2.0
http://odetocode.com/Blogs/scott/arc...1/15/2464.aspx
<quote>
Note: the Publish command does not change the debug setting in web.config.
The Publish command always compiles for "release", however, if you
precompile to an updateable web site, and then update the web site in place
(which results in dynamic compilations), those dynamic compilations will
produce debug code and pdb files.

...

Unlike the Publish command, a WSD Release build will change the debug
setting of web.config to false. The WSD also defaults to placing release
builds in a Release directory and debug builds in a Debug directory, which
is familiar to anyone using .NET outside of web forms. WSD is an awesome
tool and I'm sure will be covered in more detail here (eventually).
</quote>



Hope this helps.


Regards,
Walter Wang ((E-Mail Removed), remove 'online.')
Microsoft Online Community Support

==================================================
When responding to posts, please "Reply to Group" via your newsreader so
that others may learn and benefit from your issue.
==================================================

This posting is provided "AS IS" with no warranties, and confers no rights.

 
Reply With Quote
 
muriwai
Guest
Posts: n/a
 
      31st May 2007
Great! Thanks for the useful info.



"Walter Wang [MSFT]" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> Hi muriwai,
>
> I believe following article can help answer your question:
>
> #K. Scott Allen : Debug and Release Builds in ASP.NET 2.0
> http://odetocode.com/Blogs/scott/arc...1/15/2464.aspx
> <quote>
> Note: the Publish command does not change the debug setting in web.config.
> The Publish command always compiles for "release", however, if you
> precompile to an updateable web site, and then update the web site in
> place
> (which results in dynamic compilations), those dynamic compilations will
> produce debug code and pdb files.
>
> ..
>
> Unlike the Publish command, a WSD Release build will change the debug
> setting of web.config to false. The WSD also defaults to placing release
> builds in a Release directory and debug builds in a Debug directory, which
> is familiar to anyone using .NET outside of web forms. WSD is an awesome
> tool and I'm sure will be covered in more detail here (eventually).
> </quote>
>
>
>
> Hope this helps.
>
>
> Regards,
> Walter Wang ((E-Mail Removed), remove 'online.')
> Microsoft Online Community Support
>
> ==================================================
> When responding to posts, please "Reply to Group" via your newsreader so
> that others may learn and benefit from your issue.
> ==================================================
>
> This posting is provided "AS IS" with no warranties, and confers no
> rights.
>



 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
debug/release web.config? musosdev Microsoft ASP .NET 3 8th Jul 2008 12:33 PM
Debug=true in config same as IDE? john_c Microsoft ASP .NET 1 12th Mar 2007 05:39 PM
Config Mgr Debug/Release and Web.config Compilation debug=true RonL Microsoft ASP .NET 0 8th Apr 2006 04:50 PM
Debug = true/false in web.config Steve Franks Microsoft ASP .NET 1 7th Nov 2005 08:13 PM
debug settings in web.config and VS.NET headware Microsoft ASP .NET 2 4th Nov 2004 07:52 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 06:44 PM.