Solved

Error: Unrecognized attribute 'targetFramework'

Posted on 2011-02-23
3
1,355 Views
Last Modified: 2012-05-11
Hello,

I'm trying to get an ASP.NET application running on my local PC.

I have the site set in IIS 7 to use an Application pool version 4.0.30319

When I try to build the site in Visual Studio 2008, I get a Configuration error "Unrecognized attribute 'targetFramework'." at the line in web.config...

<compilation debug="false" targetFramework="4.0" />

The version information at the bottom of the browser error says that the .NET Framework is 2.0.50727.4952

So, it looks like there is an issue here.

How do I fix this?
0
Comment
Question by:skbohler
[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
3 Comments
 
LVL 70

Accepted Solution

by:
Éric Moreau earned 500 total points
ID: 34960765
VS 2008 cannot target 4.0. Only VS2010 can. Looks like your solution has been open/created in VS2010.

Try removing that tag from your web.config or open the solution in VS2010.
0
 

Author Comment

by:skbohler
ID: 34960947
OK, I opened it with VS2010, and it works. Thank you.
0
 
LVL 3

Expert Comment

by:DanMerk
ID: 34960950
You should be able to set it to 3.5 without any issues. The difference between 3.5 and 4 is typically very small.
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

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

Suggested Solutions

ASP.Net to Oracle Connectivity Recently I had to develop an ASP.NET application connecting to an Oracle database.As I am doing it first time ,I had to solve several problems. This article will help to such developers  to develop an ASP.NET client…
User art_snob (http://www.experts-exchange.com/M_6114203.html) encountered strange behavior of Android Web browser on his Mobile Web site. It took a while to find the true cause. It happens so, that the Android Web browser (at least up to OS ver. 2.…
With Secure Portal Encryption, the recipient is sent a link to their email address directing them to the email laundry delivery page. From there, the recipient will be required to enter a user name and password to enter the page. Once the recipient …
The Email Laundry PDF encryption service allows companies to send confidential encrypted  emails to anybody. The PDF document can also contain attachments that are embedded in the encrypted PDF. The password is randomly generated by The Email Laundr…

734 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