Today, I learned another painful lesson using Visual Studio 2005 to edit a live ASP.Net 1.1 page (.aspx file) – after I made some minor change on html codes and saved it back , the whole site blew up. What happened was that VS2005 automatically inserted a few .net 2.0 assemblies into the web.config file on the live server, even I just pull down a file to local machine and used my VS2005 to edit it.
These are those assemblies that were added by VS2005:
<add assembly=”System.Web, Version=2.0.0.0, Culture=neutral, PublicKeyToken=B03F5F7F11D50A3A”/>
<add assembly=”System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=B77A5C561934E089″/>
<add assembly=”System.Configuration, Version=2.0.0.0, Culture=neutral, PublicKeyToken=B03F5F7F11D50A3A”/>
<add assembly=”System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=B03F5F7F11D50A3A”/>
<add assembly=”System.Xml, Version=2.0.0.0, Culture=neutral, PublicKeyToken=B77A5C561934E089″/>
Previously I used either VS2003, notepad or VS2008/2010 to edit the same page and never encountered something like this. So this must be some VS2005 specific bug and Microsoft probably realized that it did too much automation in VS2005 and fixed that in later versions of VS.
So never edit a .net 1.1 ASP.Net webpage inside VS2005. It is fine to use VS2003, VS2008 or VS2010, though.