Framework versioning issues

C

Conceptor

Hi all,

1) Can an assembly built with framework 1.1 instanciate objects from another
assembly built with framework 2.0 or 3.5? Are there any
restrictions/limitations?

2) Can an assembly built with framework 2.0 or 3.5 subclass objects from
another assembly built with framework 1.1? Are there any
restrictions/limitations?

Thanks!

-C.
 
J

Jeroen Mostert

Conceptor said:
1) Can an assembly built with framework 1.1 instanciate objects from another
assembly built with framework 2.0 or 3.5?

Yes, but only if the 1.1 assembly is being loaded by the 2.0 CLR. If the
assembly is an .EXE you have .NET 1.1 installed, you must use the
<supportedRuntime> element in the configuration file to specify that it must
run as 2.0. Otherwise the 1.1 CLR will start and this cannot load 2.0
assemblies.
Are there any restrictions/limitations?
No.

2) Can an assembly built with framework 2.0 or 3.5 subclass objects from
another assembly built with framework 1.1? Are there any
restrictions/limitations?
Yes, and no.

One thing you may have to look out for is minor (and not so minor) semantic
changes in framework methods. For example, in 1.1, an unhandled exception
was discarded; in 2.0 it terminates the application. Your 1.1 code will play
by the 2.0 rules.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top