G
Guest
I can't seem to find one spot on the net that specifies exactly what I need
to do. Situation:
Native dll needs to hold a static reference to a managed class in .net 2.0
(whidbey) which needs to hold a static reference to managed classes.
1. In 2003 I needed special initialization because of the loader lock issue.
In 2005 it seems I dont need this, however I am calling into a managed dll
from a native dll, and I read somewhere there can still be an issue? Is this
true?
2. I need to keep some managed objects loaded into memory. Since the native
dll loads the managed dll, the native dll needs to hold a static rf. I will
need some sort of mixed dll, so the native dll can hold a reference to the
mixed mode dll, which can internaly load the required .net objects and keep
them in memory. However managed c++ libraries cannot maintain a static
reference to a managed object. I read I can put this static reference inside
a managed class. What do I need to do so I can load this managed class in
native code (what kind of wrapper or magic needs to be done?)
Thanks!
to do. Situation:
Native dll needs to hold a static reference to a managed class in .net 2.0
(whidbey) which needs to hold a static reference to managed classes.
1. In 2003 I needed special initialization because of the loader lock issue.
In 2005 it seems I dont need this, however I am calling into a managed dll
from a native dll, and I read somewhere there can still be an issue? Is this
true?
2. I need to keep some managed objects loaded into memory. Since the native
dll loads the managed dll, the native dll needs to hold a static rf. I will
need some sort of mixed dll, so the native dll can hold a reference to the
mixed mode dll, which can internaly load the required .net objects and keep
them in memory. However managed c++ libraries cannot maintain a static
reference to a managed object. I read I can put this static reference inside
a managed class. What do I need to do so I can load this managed class in
native code (what kind of wrapper or magic needs to be done?)
Thanks!