this. __curious_geek
this. __curious_geek

Reputation: 43207

Can I use C# 4.0 in VS2008 / ASP.NET 3.5 application?

Can I certainly do this ? If this is possible how do we do this ? What language features of C# 4.0 are tightly bound to the CLR of .net 4.0 framework if any? In case if no features are bound to CLR4.0 can we really use C#4.0 in a .Net3.5 application ?

Upvotes: 0

Views: 325

Answers (3)

Rowland Shaw
Rowland Shaw

Reputation: 38130

You cannot use any version later than 3.5 in VS2008.

You can benefit from some of the syntactical enhancements (and other compiler goodness), and still compile as against 3.5 in VS2010 though, which may save having to deploy a newer version of the framework.

Upvotes: 1

Len
Len

Reputation: 2145

I guess not, However, if you are using an 4.0 project as a reference in a 3.5 project, try to set the 4.0 to 3.5 in your projectsettings.

Upvotes: 0

TomTom
TomTom

Reputation: 62093

NO, you can not - you also can not cook a vegetarian steak.

C# 4.0 basically is all about runtime and uses a different set of... assemblies. So, no - you can not. An ASP.NET 3.5 application will have to use the corresponding version of the compiler. THe other way around it works ;)

Upvotes: 1

Related Questions