Coding Microsoft

How to execute a .NET 1.1 Application with .NET 1.0 framework?

I had written my URLDecode in Visual Studio 2003 (.NET Framework 1.1). Though I didn’t use any Framework 1.1 specific feature in my application, it won’t run by default in a machine with .NET Framework 1.0. This means I am limiting my target audience.

.NET supports something called as “Assembly Config” files, which have a file name in the format <ASSEMBLYNAME>.EXE.CONFIG. For example, if you application is named Note.EXE, then you can create an XML Configuration Note.EXE.CONFIG and have it placed in the same folder as your EXE. In a way these are for Windows Application, what is Web.Config is for ASP.NET Applications. The configuration settings specified will affect the execution of your assembly. The settings can include, CLR binding redirections. This means I can write a *.CONFIG file that will redirect references from 1.1 assemblies and CLR to 1.0 versions of same.

I wanted to create this file manually for URLDecode for sometime now. Recently I found Snippet Compiler download page has a similar config file for their software to do the same. I then customized it a little. You can use this generic configuration file for any .NET 1.1 application and have it execute in .NET 1.0. The caveat ofcourse, is that if the application uses any 1.1 feature, it is going to fail.

Download the generic config here (0.83 KB)