Home All Groups Group Topic Archive Search About

VB6 app with .Net 1.1 and .Net 2.0 controls?

Author
26 Apr 2006 8:44 PM
holysmokes99
I am working on a large project that currently is based primarily in
VB6. There are a number of .Net 1.1 assemblies that are used and
registered via regasm in the VB6 application. Is it possible to also
use 2.0 assemblies in the same VB6 app, or can only one .Net framework
be loaded at any time? If only one at a time, I guess the only way to
utilize the 2.0 framework in the application is to convert all the 1.1
assemblies to 2.0. I hope I don't need to do that.

Thanks,
Marcus

Author
26 Apr 2006 9:42 PM
Mattias Sjögren
>Is it possible to also
>use 2.0 assemblies in the same VB6 app, or can only one .Net framework
>be loaded at any time?

Only one version per process.


>If only one at a time, I guess the only way to
>utilize the 2.0 framework in the application is to convert all the 1.1
>assemblies to 2.0. I hope I don't need to do that.

No, you just have to make sure the 2.0 CLR gets loaded. It should run
the 1.1 assemblies as well.


Mattias

--
Mattias Sjögren [C# MVP]  mattias @ mvps.org
http://www.msjogren.net/dotnet/ | http://www.dotnetinterop.com
Please reply only to the newsgroup.
Author
26 Apr 2006 10:21 PM
holysmokes99
So the 2.0 CLR will run 1.1 assemblies as well? I did not know that.
How do I ensure that the 2.0 gets loaded and not the 1.1?

Thanks,
Marcus
Author
27 Apr 2006 5:43 AM
Mattias Sjögren
>So the 2.0 CLR will run 1.1 assemblies as well? I did not know that.
>How do I ensure that the 2.0 gets loaded and not the 1.1?

You can use a config file, just like for a managed application. See

http://msdn.microsoft.com/library/en-us/cpguide/html/cpconconfiguringcomapplicationforside-by-sideexecution.asp


Mattias

--
Mattias Sjögren [C# MVP]  mattias @ mvps.org
http://www.msjogren.net/dotnet/ | http://www.dotnetinterop.com
Please reply only to the newsgroup.

AddThis Social Bookmark Button