There were no types found in the assembly.....

Topics: Exception Handling Application Block
Jan 22, 2010 at 10:25 AM
Edited Jan 22, 2010 at 10:41 AM


I have two projects in my solution-

ClassLibrary1 (DLL)

ConsoleApplication1 (.exe)

I'd like to select a new exception type in policy in App.config (ConsoleApplication1.exe) file. I have defined that exception in ConsoleApplication1.exe. When try to refer that exception from TypeSelector->Load From File->ConsoleApplication1.exe. It gives the error message-

"There were no types found in the assembly ConsoleApplication1.exe that implement or inherit from the base type 'System.Exception'.  I'm not getting why it is not finding the exception defined in ConsoleApplication1.exe file. But when I define same exception in ClassLibrary1.dll, it is able to find the exception class.

Can somebody explain me this behavior? I'm using Entlib 4.1 and I'm new to this stuff.





Jan 25, 2010 at 1:14 AM

I'm not able to repro this.  A possible explanation is that ConsoleApplication.exe was previously loaded and the attempt to load a new version would not be successful. (Related thread -  Just try opening and closing the visual studio ide.


Sarah Urmeneta
Global Technology and Solutions
Avanade, Inc.