Josh
Josh

Reputation: 13828

Using .Net framework 3.5 features in .Net framework 2.0

Is it possible to convert some of the dlls of .Net framework 3.5 and use it in .Net framework 2.0?

I really need the managed named pipes namespace in .Net 2.0 :-(

Thanks

Upvotes: 1

Views: 1001

Answers (6)

Max Toro
Max Toro

Reputation: 28618

Yes, you can. I've done it. I use System.Core, System.Xml.Linq, System.Data.Linq, and other 3.5 stuff on a Windows 2000 server with .NET 2.0

There's no need to 'convert' anything, 3.5 assemblies (green bits) target the 2.0 version of the CLR. What you need to do is install the latest service pack for .NET 2.0 (SP2 I think), that will update the red bits assemblies.

http://www.danielmoth.com/Blog/2007/06/net-framework-35.html

Upvotes: 4

Ryan Lundy
Ryan Lundy

Reputation: 210360

Here's a good blog post which (along with one or two following it) goes into detail about what you can use in .NET 2.0 with no changes, what you can't, and what you can with a workaround or two:

Using C# 3.0 from .NET 2.0

Upvotes: 0

Jn.
Jn.

Reputation: 19

Simple answer: No. :)

Upvotes: 1

Marc Gravell
Marc Gravell

Reputation: 1063994

You can use the C# 3.0 compiler features in .NET 2.0 with a few tricks - but you aren't going to be able to use framework dlls / types / methods that don't exist in 2.0. I don't recommend trying to simply deploy any 3.5 dlls without having the client have .NET 3.5 installed. My expectation is that you'll have to install .NET 3.5 on the machine, or make do without the framework feature you want.

Upvotes: 4

Lucas
Lucas

Reputation: 339

It depends on what features of .net 3.5 that dll is using. Most of the code is the same with the 2.0 version. Most of the Linq can be implemented is 2.0. BUT... there are some things that in 2.0 just will not work... you will have to try and see.

Upvotes: 1

Mitch Wheat
Mitch Wheat

Reputation: 300759

You can use some of the features of .NET Framework 3.5 in .NET Framework 2.0 using LINQBridge, but not that particular namespace you mentioned AFAIK.

Upvotes: 1

Related Questions