How to use ApplicationManager to load an object with out GAC'ing it?

649 views Asked by At

I'm trying to use the Cassini webserver to create a deployment test host- a sort of embedded web server to isolate web server config issues from app deployment issues. Okay, so this line of code blows up until I put Cassini in the GAC:

 // physical path points to the bin folder with the dll
_host = (Host)_appManager.CreateObject(appId, typeof(Host),
                                   _virtualPath, _physicalPath, 
                                   false /*failIfExists*/);

The above fails with FileNotFoundException -- as if it is trying to find the Cassini.dll

Should I just be able to tell ApplicationManager where to look without taking the extreme step of putting it into the GAC?

I am using Cassini 2.1 and the source code is here.

1

There are 1 answers

1
Cheeso On BEST ANSWER

I believe I had a similar problem and what I needed to do was put the searched-for DLLs into a bin subdirectory.

If the searched-for DLLs are located in the current directory, it's enough to create a junction point called "bin" that refers to the current directory.