Solved

Downgrading to asp.net 2.0

Posted on 2010-09-21
5
405 Views
Last Modified: 2012-05-10
I have build an asp.net website using Visual Studio 2008 and .NET Framework 3.5.
When published on the server (Windows server 2003), it throwing the attached error. (Line 104)
I think its because the server uses .NET Framework 2.0. If changing the .NET framework on the server is not an option, how can I change the Framework on my website ? Are there any changes that can be made on IIS without disturbing the existing websites on it?

In VS 2008, I went to Website -> Start Options -> Build -> selected .NET Framework 2.0 and recompiled the website. I did not see any change in the code or web.config file after that. Are the changed files hidden?
Also, doing this still did not get rid of the error. Any ideas please?
Parser Error Message: Child nodes not allowed.

Source Error:

Line 102:		<compilers>
Line 103:			<compiler language="c#;cs;csharp" extension=".cs" warningLevel="4" type="Microsoft.CSharp.CSharpCodeProvider, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
Line 104:				<providerOption name="CompilerVersion" value="v3.5"/>
Line 105:				<providerOption name="WarnAsError" value="false"/>
Line 106:			</compiler>

Open in new window

0
Comment
Question by:Angel02
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
5 Comments
 
LVL 28

Accepted Solution

by:
strickdd earned 350 total points
ID: 33727181
You've done the hard part of downgrading the project itself. Now if you create a web.config for the app it will be a 2.0 web.config and you can port your current settings to the new one. That should fix your problem.
0
 
LVL 21

Expert Comment

by:chapmanjw
ID: 33727563
Is the .NET 3.5 framework installed on the Windows Server 2003 box?
0
 

Author Comment

by:Angel02
ID: 33728484
@chapmanjw
.NET 3.5 is NOT installed on the Windows 2003. Does it matter if the website is not using it anyway ?
0
 
LVL 21

Assisted Solution

by:chapmanjw
chapmanjw earned 150 total points
ID: 33728548
I would either take the compilers section completely out of your web.config or install .NET 3.5 on the server and set your target back to 3.5.  VS doesn't make all the changes necessary on an existing app automatically when you change the target framework.
0
 

Author Comment

by:Angel02
ID: 33728652
Thanks, as you said and as strickdd indicated above, recreating the web.config, after changing the target framework fixed the issue. Now the website is actually using .NET 2.0.
Works perfect when new installations on the server are not feasible. Thank You !
0

Featured Post

Does Your Cloud Backup Use Blockchain Technology?

Blockchain technology has already revolutionized finance thanks to Bitcoin. Now it's disrupting other areas, including the realm of data protection. Learn how blockchain is now being used to authenticate backup files and keep them safe from hackers.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Parsing a CSV file is a task that we are confronted with regularly, and although there are a vast number of means to do this, as a newbie, the field can be confusing and the tools can seem complex. A simple solution to parsing a customized CSV fi…
Lync server 2013 or Skype for business Backup Service Error ID 4049 – After File Share Migration
There's a multitude of different network monitoring solutions out there, and you're probably wondering what makes NetCrunch so special. It's completely agentless, but does let you create an agent, if you desire. It offers powerful scalability …
Sometimes it takes a new vantage point, apart from our everyday security practices, to truly see our Active Directory (AD) vulnerabilities. We get used to implementing the same techniques and checking the same areas for a breach. This pattern can re…

623 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question