AppDomains and Assemblies. I'm trying to search through a folder of assemblies for the one that contains my target class (which must implement IExecuteReport). Once I find this class I want to create an instance of it and invoke the Execute() method. Currently I'm having issues with the AppDomain.Load(). What I don't understand is why am I getting a "System.IO.FileNotFoundException" exception on the Assembly asm = ad.Load(rawAssembly); line. I am already loading the assembly with loadFile(string filename). I am also referencing the same assemblies as the target assembly. Any ideas? [StronglyTyped - Richard Caetano's weblog on software development]
//byte[] rawAssembly = loadFile(filename); AssemblyName an = new AssemblyName(); an.CodeBase = filename; Assembly asm = ad.Load(an);
stopped FileNotFoundException-ing for me
10:22:00 PM
|