Link to home
Start Free TrialLog in
Avatar of Number5ix
Number5ixFlag for Australia

asked on

ASP.NET website set to debug="false" but on compile always says Debug .NET - why?

Hi,

I've got an ASP.NET (VB.NET) 2.0 web application and the Web.config file has the following line :

<compilation defaultLanguage="vb" debug="false" />

According to the Microsoft documentation this means debug symbols etc won't be compiled into the app - cool so far.

Problem is, when I publish, build or rebuild the solution/website the compilation output window says :

------ Build started: Project: Y:\...\xxx\, Configuration: Debug .NET ------

Why is this?   Shouldn't it say Release .NET because I have debug="false" in Web.config?   I've checked Web.config and machine.config in C:\Windows\Microsoft.NET\Framework\<version>\CONFIG but there's no mention of debug in either of them.

Can anyone help solve this?

Thanks
Chris
ASKER CERTIFIED SOLUTION
Avatar of Carl Tawn
Carl Tawn
Flag of United Kingdom of Great Britain and Northern Ireland image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of Number5ix

ASKER

Ok looks like we're getting somewhere.   I actually looked there and thought that would be a logical place for the Release configuration thing to be ... but all I have in that list is "Debug".   I see there's an option to delete configurations but this is a relatively new install of VS.NET 2005 and nobody has used this machine but me - I haven't deleted the Release configuration.

I can put one back called "Release" but I'm not sure if that's the right way to do it ... can you help?   (you'll get the points anyway, just don't want to close the question yet).   :)

Thanks!
I also found http://odetocode.com/Blogs/scott/archive/2005/11/15.aspx which says :

"Publish will always precompile a release build without debugging symbols."

Does that mean the way I'm doing it (which is using Publish when making the site go live) is the correct way already?   That article also says something about the Debug configuration being the only configuration available.
Sound like you're doing it right then. The "Debug" on the build output must be ignored or overridden automatically bt the publication process. You can find out what happens during the publish process here:

    http://msdn2.microsoft.com/en-us/library/e22s60h9(VS.80).aspx
Thanks for your help.   Here, have some points.   :)