views:

482

answers:

1

Overview: I'm interested in learning more about the .NET4 "In-Process Side-by-Side Execution" of assemblies, and need additional information to help me demystify it.

Motivation: The application in question is built against .NET2, and uses two third-party libraries that also work against .NET2. The application is deployed (via file copy) to client machines in a virtual environment that includes .NET2. Not my architecture, please bear with me.

Goal: To see if it's possible to rebuild the application assemblies (or a subset) against .NET4, and ship the application as before, without changing the third-party libraries and including the .NET4 Client Profile (as described here) in the deployment.

Steps Taken: The following articles were read, but didn't quite provide me enough information:

  1. In-Process Side-by-Side Execution: Browsed this article, and Scenario Two is the closest it comes to describing something that resembles my situation, but doesn't really cover it with any depth.

  2. ASP.NET Side-by-Side Execution Overview: This article covers a web application, but I'm dealing with a client WinForms application.

  3. CLR Team Blog: In-Process Side-by-Side: This is useful to explain how plug-ins to host processes function under .NET4, but I don't know if this applies to the third-party libraries.

Further Steps: I'm also unclear on how to proceed upgrading a single .NET2 assembly to .NET4, with the executable remaining in .NET2 (i.e. how to configure the solution/project files, if any special code needs to be included, etc.).

+1  A: 

In general, you can load assemblies created against .NET 2 in the .NET 4 runtime. So you should try this first and see if it "just works". Just covert your app to VS 2010 / .NET 4, and try to compile it with the same references to the third party assemblies. Then deploy and it will probably work.

jkohlhepp