Web Project Build Adds Assemblies to Web.Config?

Last post 05-30-2008 8:23 PM by ryan.smith. 4 replies.

Sort Posts:

  • Web Project Build Adds Assemblies to Web.Config?

    03-15-2007, 3:44 PM
    • Loading...
    • jonwillis
    • Joined on 07-11-2003, 11:09 AM
    • Springfield, MO, US
    • Posts 43

    I've got an ASP.NET application that I develop on my local machine and deploy to a Win Server 2003 server after testing.  The Web application runs just fine on the Web server, so there's not really a problem except...I got configuration errors the first time I deployed the site to the server because of all of the Microsoft.VisualBasic.xxx references added to the compilation/assemblies section of web.config. So...I removed them all and redeployed to the server. Voila! A working site!

    Now, whenever I rebuild the project, Visual Studio attempts to check web.config out of VSS and modify it.  This breaks my deployment so I have to keep removing the references. Is there a reason for this?  I'm attaching the compilation section of my web.config without all of the useless references:

     

    <compilation debug="true" defaultLanguage="vb" explicit="true" strict="false">
    <assemblies>
    <add assembly="System.Data.OracleClient, Version=2.0.0.0, Culture=neutral, PublicKeyToken=B77A5C561934E089"/>
    <add assembly="System.Runtime.Serialization.Formatters.Soap, Version=2.0.0.0, Culture=neutral, PublicKeyToken=B03F5F7F11D50A3A"/>
    <add assembly="System.Web.Extensions, Version=1.0.61025.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
    <add assembly="System.Web.Extensions.Design, Version=1.0.61025.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
    </assemblies>
    </compilation>
     

    Could it be because I have debug set to true (which I always need to remember to change before deployment)?

    Procrastination: Don't put if off for another minute!
  • Re: Web Project Build Adds Assemblies to Web.Config?

    09-25-2007, 9:03 AM
    • Loading...
    • jonwillis
    • Joined on 07-11-2003, 11:09 AM
    • Springfield, MO, US
    • Posts 43

    This behavior doesn't make any sense but there's obviously no solution to it so I'll mark it as resolved to get it off of the unanswered questions list.

    Procrastination: Don't put if off for another minute!
  • Re: Web Project Build Adds Assemblies to Web.Config?

    09-25-2007, 1:33 PM
    Answer
    • Loading...
    • hongping
    • Joined on 11-02-2006, 9:42 PM
    • Posts 434
    • AspNetTeam

    Seems similar to this reported issue: http://forums.asp.net/p/924162/1068585.aspx

    ==============================================
    If you get the answer to your question, please mark it as the answer.
  • Re: Web Project Build Adds Assemblies to Web.Config?

    09-25-2007, 4:47 PM
    • Loading...
    • jonwillis
    • Joined on 07-11-2003, 11:09 AM
    • Springfield, MO, US
    • Posts 43

    Yeah, you're absolutely right. What a shame there's no fix. Thanks.

    Procrastination: Don't put if off for another minute!
  • Re: Web Project Build Adds Assemblies to Web.Config?

    05-30-2008, 8:23 PM
    • Loading...
    • ryan.smith
    • Joined on 05-30-2008, 8:20 PM
    • Posts 2

    We managed to fix the auto-adding of DLL references to web.config by appending to the registry key [HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\VisualStudio\8.0\Projects\{E24C65DC-7377-472B-9ABA-BC803B73C61A}\FilteredGACReferences] as described at http://davidovitz.blogspot.com/2006/03/webconfig-contains-assembly-references.html


     

Page 1 of 1 (5 items)
Microsoft Communities
Page view counter