Unable to run logging exercise of Microsoft Enterprise Library 5.0 - Hands On Labs

Topics: Logging Application Block
May 28, 2010 at 5:17 PM

Hello all,

I've installed the Microsoft Enterprise Library 5.0 - Hands On Labs to try the logging examples.

They are located in Microsoft Enterprise Library 5.0 - Hands On Labs\CS\Logging\exercises\.

I've tried "ex01" ("EnoughPI"), but I can't get it working using .net 3.5 neither with Visual Studio 2008 nor Visual Studio 2010.

I've always getting System.ExecutionEngineException.

I've used step-by-step "\Microsoft Enterprise Library 5.0 - Hands On Labs\CS\Logging\instructions\Logging instructions CS.pdf" to add logging to "ex01\begin" project.

I've tried also "ex01\end" project.

Nothing works.

All necessary references are present, the issue is reproducible on several machines and in other projects as well.

Microsoft Enterprise Library 5.0 is also installed.


Are there any known problems with this which can be solved to get the Logging of Enterprise Library 5.0 working?

Are there any steps which are missed in instructions and/or "ex01\end" project?

Thank you very much!




May 31, 2010 at 1:33 AM

I tried it out and didn't encounter this issue.  What is the exception message you're getting?  Does the exception occur right after you start running the application or upon pressing the button within the form?

Sarah Urmeneta
Global Technology & Solutions
Avanade, Inc.

Jun 7, 2010 at 7:29 PM
I'm seeing this too, right after calling Logger.Write();
Jun 8, 2010 at 8:31 AM

I really don't know what the reason behind the raised exception as we are unable to reproduce it from our end. The exception type System.ExecutionEngineException as per http://msdn.microsoft.com/en-us/library/system.executionengineexception.aspx is an exception thrown by the execution engine of the CLR (this class is already obsolete in .Net Framework 4).  

I've seen some other forum post in the internet regarding this, though I haven't really tried this here is one http://bytes.com/topic/visual-basic-net/answers/612133-unhandled-exception-type-system-executionengineexception-occurred-system-data-dll that said to be resolved by repairing the .NET Framework installed in his computer.

Gino Terrado
Global Technology and Solutions
Avanade, Inc.


Jun 10, 2010 at 10:53 PM
If it helps, this is a 32-bit .NET 3.5 app, not .NET 4. Is entlib 5 not supported in .NET 3.5 SP1? If so then I guess that's the problem. Rolling back to entlib 4 resolved it for me.
Jun 11, 2010 at 2:30 AM

EntLib 5 is fully supported in .NET 3.5 SP1.   Isn't there any other exception message included?  It might give us a clue as well as the stack trace.  Check also if there's an inner exception. 


Sarah Urmeneta
Global Technology & Solutions
Avanade, Inc.