469,592 Members | 1,923 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,592 developers. It's quick & easy.

Load and unload DLL's. Possible?

Hello,

What I want to do is to create DLL that I can load and use and then unload
when needed.
What I mean by this is: After object released - dll file can be removed,
etc. So, file won't be blocked.
Now I use regular EXE and pass command line but I need to pass objects, so
EXE doesn't work well anymore.

Thank you,
Ivan

Nov 13 '08 #1
1 3469
Ivan,

Generally, if you load the assembly manually, you won't be able to
unload the assembly unless you unload the entire app domain. To get around
this, you would usually spin up a new app domain and then create the object
in that domain, and then unload the domain when done.

You can use the classes in the System.AddIn namespace now to do what you
want though, as opposed to rolling this all yourself.
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

"Ivan" <iv**@mailgroups.microsoft.comwrote in message
news:3D**********************************@microsof t.com...
Hello,

What I want to do is to create DLL that I can load and use and then unload
when needed.
What I mean by this is: After object released - dll file can be removed,
etc. So, file won't be blocked.
Now I use regular EXE and pass command line but I need to pass objects, so
EXE doesn't work well anymore.

Thank you,
Ivan

Nov 13 '08 #2

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

2 posts views Thread by Patrick Blackman | last post: by
3 posts views Thread by Alex S. | last post: by
2 posts views Thread by Lauren Hines | last post: by
2 posts views Thread by Razzie | last post: by
2 posts views Thread by brianbender | last post: by
3 posts views Thread by Frank Uray | last post: by
2 posts views Thread by chandu | last post: by
reply views Thread by suresh191 | last post: by
4 posts views Thread by guiromero | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.