Click here to Skip to main content
15,888,816 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
My code for web.config is givenbelow
XML
<configuration>
	<system.web>
		<compilation debug="true" targetframework="4.0" />
	</system.web>
  <system.web>
    <customerrors mode="Off" />
  </system.web>
</configuration>


Details errors are given below


Configuration Error
Description: An error occurred during the processing of a configuration file required to service this request. Please review the specific error details below and modify your configuration file appropriately.

Parser Error Message: Unrecognized attribute 'targetFramework'. Note that attribute names are case-sensitive.

Source Error:

Line 2:  <configuration>
Line 3:  	<system.web>
Line 4:  		<compilation debug="true" targetframework="4.0" />
Line 5:  	</system.web>
Line 6:    <system.web>
</system.web></configuration>
Posted
Updated 8-Nov-18 8:49am
v3
Comments
[no name] 6-Dec-11 3:38am    
EDIT: added "pre" tag
uspatel 6-Dec-11 3:39am    
have you installed .net 4.0 framework
[no name] 6-Dec-11 4:40am    
it is included in vs2010

If your are using your application in visual studio 2008 then try to remove
the tag targetframework="4.0".

Mostly these type of error(s) occur if your compiling and debugging the projects in different version of dotnet.
 
Share this answer
 
If your are using your application in visual studio 2008 then try to remove
the tag targetframework="4.0".
It worked for me.
 
Share this answer
 
Comments
Blutfaust 8-Nov-18 16:17pm    
Well, this question is SEVEN years old. I think the OP has already found a solution.
CHill60 9-Nov-18 4:47am    
We're now supposed to allow solutions to really old posts go through ... unless of course they have just copied someone else's solution as in this case :-)
Blutfaust 10-Nov-18 14:38pm    
Ah, okay. I haven't been aware of that.
CHill60 9-Nov-18 4:46am    
Don't just repeat other members' solutions. You could have added "It worked for me" as a comment to solution 1

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900