Event Source Changes Not Compiling

Topics: General
Jun 12, 2014 at 5:06 AM
I have added two new event methods to an EventSource derived class, yet when I build the project, it's as if they are not there. There are no syntax errors, and that project builds fine, but projects that reference it just don't see the new methods. Must I reference the DLL rather than the project or something, or set the registertool to clear its cache or something?
Jun 16, 2014 at 5:25 AM
That's strange. At compile time EventSource methods are just standard .NET methods so should compile fine if the assembly referenced. Are you sure you are referencing the correct assembly? I've occasionally seen assemblies referenced from the bin\Debug folder but when the build is changed to Release and the assembly is built in the bin\Release folder the changes are not picked up.

If you select the reference and hit F4 for the Properties Window what is the path that is being referenced? Is that the correct assembly. Check to see if your methods are there by opening it in a disassembler (e.g. a reflection tool or ILDASM).

Randy Levy
Enterprise Library support engineer
Support How-to