Appdomain cannot load assembly... why?
Appdomain cannot load assembly... why?
am 14.01.2008 16:21:52 von ThunderMusic
Hi, (My code is at the end of this post)
I have an AppDomain that must load a simple assembly that has only one class
with one method and it does not work... I receive this exception : "Could
not load file or assembly 'ModuleLoader.dll' or one of its dependencies. The
system cannot find the file specified."
Does anyone have an idea of something I'm missing?
Thanks
ThunderMusic
[Code]
*** Main App (calling method) ***
AppDomainSetup ads = new AppDomainSetup();
ads.ApplicationBase = AppDomain.CurrentDomain.BaseDirectory;
ads.PrivateBinPath = AppDomain.CurrentDomain.BaseDirectory;
ads.DisallowBindingRedirects = false;
ads.DisallowCodeDownload = true;
m_CurrentMonitorAppDomain = AppDomain.CreateDomain("MonitorLoader", null,
ads);
// The following call fails
MonitoringModuleLoader mml =
(MonitoringModuleLoader)m_CurrentMonitorAppDomain.CreateInst anceAndUnwrap("ModuleLoader.dll",
"ModuleLoader.MonitoringModuleLoader");
*** The "ModuleLoader" library ***
namespace ModuleLoader
{
public class MonitoringModuleLoader : MarshalByRefObject
{
public MonitoringModuleLoader()
{
}
public MonitorBase Load(byte[] LibBytes, string ModuleName)
{
return null;
}
}
}
[/Code]
Re: Appdomain cannot load assembly... why?
am 14.01.2008 17:10:48 von ThunderMusic
finally, I found the problem... I was using 'CreateInstanceAndUnwrap' and
should have used 'CreateInstanceFromAndUnwrap'
Thanks
"ThunderMusic" wrote in message
news:eqB$sFsVIHA.1208@TK2MSFTNGP05.phx.gbl...
> Hi, (My code is at the end of this post)
>
> I have an AppDomain that must load a simple assembly that has only one
> class with one method and it does not work... I receive this exception :
> "Could not load file or assembly 'ModuleLoader.dll' or one of its
> dependencies. The system cannot find the file specified."
>
> Does anyone have an idea of something I'm missing?
>
> Thanks
>
> ThunderMusic
>
> [Code]
>
> *** Main App (calling method) ***
> AppDomainSetup ads = new AppDomainSetup();
> ads.ApplicationBase = AppDomain.CurrentDomain.BaseDirectory;
> ads.PrivateBinPath = AppDomain.CurrentDomain.BaseDirectory;
> ads.DisallowBindingRedirects = false;
> ads.DisallowCodeDownload = true;
> m_CurrentMonitorAppDomain = AppDomain.CreateDomain("MonitorLoader", null,
> ads);
> // The following call fails
> MonitoringModuleLoader mml =
> (MonitoringModuleLoader)m_CurrentMonitorAppDomain.CreateInst anceAndUnwrap("ModuleLoader.dll",
> "ModuleLoader.MonitoringModuleLoader");
>
> *** The "ModuleLoader" library ***
> namespace ModuleLoader
> {
> public class MonitoringModuleLoader : MarshalByRefObject
> {
> public MonitoringModuleLoader()
> {
> }
> public MonitorBase Load(byte[] LibBytes, string ModuleName)
> {
> return null;
> }
> }
> }
>
> [/Code]
>
Re: Appdomain cannot load assembly... why?
am 15.01.2008 23:40:56 von ThunderMusic
the text. -- The expression I have chosen for my text, their
foot shall slide in due time, seems to imply the following things,
relating to the punishment and destruction to which these wicked
Israelites were exposed. That they were always exposed to destruction;
as one that stands or walks in slippery places is always exposed to
fall. This is implied in the manner of their destruction coming upon
them, being represented by their foot sliding. The same is expressed,
Psalm 72:18. "Surely thou didst set them in slippery places; thou
castedst them down into destruction."
It implies, that they were always exposed to sudden unexpected
destruction. As he that walks in slippery places is every moment liable
to fall, he cannot foresee one moment whether he shall stand or fall the
next; and when he does fall, he falls at once without warning: Which is
also expressed in Psalm 73:18,19. "Surely thou didst set them in
slippery places; thou castedst them down into destruction: How are they
brought into desolation as in a moment!"
Another thing implied is, that they are liable to fall of themselves,
without being thrown down by the hand of another; as he that stands or
walks on slippery ground needs nothing but his own weight to throw him
down.
That the reason why they are not fallen already and do not fall now is
only that God's appointed time is not come. For it is said, that when
that due time, or appointed
Re: Appdomain cannot load assembly... why?
am 16.01.2008 01:15:01 von ThunderMusic
not be.
231. Do you believe it to be impossible that God is infinite, without parts?
Yes. I wish therefore to show you an infinite and indivisible thing. It is a
point moving everywhere with an infinite velocity; for it is one in all
places and is all totality in every place.
Let this effect of nature, which previously seemed to you impossible, make
you know that there may be others of which you are still ignorant. Do not
draw this conclusion from your experiment, that there remains nothing for
you to know; but rather that there remains an infinity for you to know.
232. Infinite movement, the point which fills everything, the moment of
rest; infinite without quantity, indivisible and infinite.
233. Infinite--nothing.--Our soul is cast into a body, where it finds
number, dimension. Thereupon it reasons, and calls this nature necessity,
and can believe nothing else.
Unity joined to infinity adds nothing to it, no more than one foot to an
infinite measure. The finite is annihilated in the presence of the infinite,
and becomes a pure nothing. So our spirit before God, so our justice before
divine justice. There is not so great a disproportion between our justice
and that of God as between unity and infinity.
The justice of God must be vast like His compassion. Now justice to the
outcast is less vast and ought less to offend our feelings than mercy
towards the elect.
We know that there is an infinite, and are ignorant of its nature. As we
know it to be false that numbers are finite, it is therefore true that there
is an infinity in number. But we do not know what it is. It is false that it
is even