Saif Khan
Saif Khan

Reputation: 18812

Changing target framework in Visual Studio 2008

What's the deal with Visual Studio?

I tried importing the Caching App Block and got this message:

The assembly or one of its dependencies you're are trying to import requires a later version of .NET Framework.

I went to the properties of my application in Visual Studio, but I can't find the dropdown to switch....what's the deal?

Upvotes: 3

Views: 22397

Answers (5)

Michael Murphy
Michael Murphy

Reputation: 81

In Visual Studio 2008, the Targeted Framework option was greyed out for me. I had to follow the instructions in article How to: Modify the Target Framework and Platform Toolset to change the Targeted Framework so that two related projects could work together.

Basically you unload the project with the wrong framework, open the project file in Visual Studio as a text file, find the line in the XML that specifies the Targeted Framework and change that to the desired framework. Save the file and reload the project.

Upvotes: 2

Jon Tackabury
Jon Tackabury

Reputation: 49319

It should be on the Application tab in the project's properties. A great article on how Visual Studio 2008 handles framework targeting is VS 2008 Multi-Targeting Support.

Upvotes: 2

Saif Khan
Saif Khan

Reputation: 18812

Found it....went to "Advanced Compile Options" on Compile Tab.....weird!

Upvotes: 7

sudarpo.net
sudarpo.net

Reputation: 61

I think they make it different for C# project and VB project.

C# project

Solution Explorer --> Project --> Properties and on the Application tab you'll see Target Framework.

VB project

Project Properties --> Compile --> Advanced Compile Options

Upvotes: 6

steve1999
steve1999

Reputation:

Go to the properties of a project (Solution Explorer --> Project --> Properties or Menu Bar --> Project --> Properties) and on the Application tab you'll see Target Framework.

Upvotes: 0

Related Questions