473,756 Members | 7,560 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Debug in web.config

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\Micr osoft.NET\Frame work\v2.0.50727 \CONFIG\machine .config
<configuratio n>
<system.web>
<compilation debug="true" />

C:\WINDOWS\Micr osoft.NET\Frame work\v2.0.50727 \CONFIG\web.con fig
<configuratio n>
<system.web>
<compilation debug="true">
...

--

May 28 '07 #1
2 2430
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 (wa****@online. microsoft.com, 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.

May 29 '07 #2
Great! Thanks for the useful info.

"Walter Wang [MSFT]" <wa****@online. microsoft.comwr ote in message
news:Gm******** ******@TK2MSFTN GHUB02.phx.gbl. ..
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 (wa****@online. microsoft.com, 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.

May 31 '07 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
11144
by: Stephen Miller | last post by:
Hi, I am running v1.1.4322 on Win2K server and unable to debug a ASP.Net application running locally, using a full URL (ie www.mysite.com). When I hit F5, I get the following error message: <debugger_error_message> Error while trying to run project: Unable to start debugging on the web server. The project is not configured to be debugged.
2
1286
by: Coder Coder | last post by:
Hi, Im want to release my web project and the configurations inside my web.config are very different from my development environment to my production environment. I was wondering is there a way to have the debug version use one web.config file, while the release version uses a release version of the web.config.
6
1830
by: Luis Esteban Valencia | last post by:
Hi, I want in debug mode debug=true. In release (production), no reason debug to be true but the questions are: 1. Does it slow the application (holding debug=true) 2. If yes, how can I solve the problem so that in debug mode debug=true and in realse debug=true. To hold 2 separate files - seems not so good idea Additional question: is there any correlation between debug in web.config
10
1810
by: Joe Befumo | last post by:
When I tried debugging for the first time, I pop-up asked me if I wanted to set the project to enable debugging. Now I'm ready to release and can't find anyplace to set the build to 'release'. A pointer would be appreciated. Thanks. Joe
3
3108
by: André | last post by:
Hi, I put that question already, but it's still not very clear to me, so ... Assume following option in web.config= debug="false" but in one aspx page (test.aspx) <%@ debug="true" ..%>
3
2871
by: Arman Sahakyan | last post by:
Hi, I'm an MFC programmer and know little about .NET programming. Now, for some reasons, I'm developing an ASP .NET application... What I need to know is how to output into VS's Output Window like what MFC's TRACE macro does (during debugging). Could you please share your knowledge with me? Thanks in advance.
4
1625
by: =?Utf-8?B?cGF0cmlja2RyZA==?= | last post by:
Hi everyone! 1) How can I include 'debug' mode code in my asp.net 2005 project? i.e. in visual basic 6 (where I come from) the developer could check if the application was running from within the IDE and write some code that would run only then. How can I do that in asp.net 2005? I've seen an example here: http://weblogs.asp.net/scottgu/archive/2006/08/12/Tip_2F00_Trick_3A00_-Show-Detailed-Error-Messages-to-Developers.aspx
1
1718
by: gfergo | last post by:
Good Morning, I seem to be having a problem. I thought I could display detailed debugging information (including file name and line number) on a page using two different methods: 1.) modify the debug attribute of the compilation element in the web.config file -
5
1801
by: Andy B | last post by:
How do you tell vs2005 to keep debug info out of your release builds? When I build a release and a debug version, there seems to be no difference in them at all...The release builds still have the debug databases with them...
0
9275
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10040
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
1
9846
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
8713
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
7248
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5142
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5304
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
3806
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
3
2666
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.