• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 417
  • Last Modified:

Is there a tool to convert a .Net 3.5 app back to 2.0?

I've written some cute, semi-useful apps.  They're in C# and .Net 3.5.  Unfortunately, a lot of the places around work where I would like to use them are machines with only .Net 2.0.  That means just to use my tool, I have to install a new framework.  Bummer.  Is there an easy way to convert a 3.5 app to 2.0?  Perhaps there is a tool out there for this?  My code goes in one side as 3.5 and comes out the other as 2.0?  Or am I stuck with basically rebuilding?  

Jeremy
0
mrcoulson
Asked:
mrcoulson
  • 2
  • 2
3 Solutions
 
Gyanendra SinghArchitectCommented:
there is no direct tool as such ... you can do one thing ... open that solution in vs2008 and select target framwork as 2.0  and compile that application ... if your code is using any specific framework feature it will throw some error else ... your application will work on 2.0 :)

before that your machine should have framework 2.0 installed
0
 
Fernando SotoRetiredCommented:
Hi mrcoulson;

Before recreating the application you may want to try the following. I have not done this myself but I don't see why it will not work. Also be aware that if you used and new 3.5 features in your code that section will need to be re-written for 2.0. Also check the reference node in Solution Explorer for any warning on the assemblies and resolve them.

Save the project folder to another location
Open the copy of the project in Visual Studio .Net
Go to Solution Explorer and right click on the Project Name and select Properties from the context menu.
Select the Application Tab
Change the Target Framework: from 3.5 to 2.0 and a warning Dialog box will appear. Read and Select Yes.
Re-open the project. If you used any assemblies that are 3.5 you will need to remove them and rewrite the sections of code that is not supported in 2.0.
Compile and test.

Fernando
0
 
mrcoulsonAuthor Commented:
Yeah, I've done that.  I'm a n00b at this and have only developed in 3.5, so going back to 2.0 is kind of like re-learning.  Here's a related question: is there a way to make Visual C# Developer's Intellisense pull from 2.0?

See, I basically have learned 70% of what I know with Intellisense.  For example, I have a control and I want to do something with it, so I type its name and wait for Intellisense to tell me what's available for the control.  Of course, after that I may need to refer to MSDN to find out more about a method or something, but at least Intellisense gives me a mental springboard.

So, is there a way to make Intellisense use 2.0?
0
 
Fernando SotoRetiredCommented:
Intellisense will display what is available on the Target .Net Framework. So if you are working in 3.5 everything that is supported in 3.5 will be shown and if you are working in 2.0 only 2.0 Functions/Methods/Types will be shown.
0
 
mrcoulsonAuthor Commented:
Oh, rad!  So if I change the target framework, Intellsense knows it.  How...um...intelligent!
0

Featured Post

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

  • 2
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now