The located assembly's manifest definition does not match the assembly reference

Topics: Data Access Application Block, Exception Handling Application Block, Logging Application Block
Oct 31, 2007 at 5:52 PM

Hello

Please help me out here before I go postal. I have a web application where I'm using the data, exception handling, and logging blocks of the Enterprise Framework Library 3.1 and I can't identify what needs to be changed to fix the following error message that I'm receiving:

"An exception of type 'System.Configuration.ConfigurationErrorsException' occurred in Microsoft.Practices.EnterpriseLibrary.Data.DLL but was not handled in user code

Additional information: An error occurred creating the configuration section handler for dataConfiguration: Could not load file or assembly 'Microsoft.Practices.EnterpriseLibrary.Data, Version=3.1.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies. The located assembly's manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040)"

I have recompiled all dll's; removed and re-included the references to the newly created dll's, and used the configuration tool to create the web.config file that also references the newly created dll's.

Thanks in advance
Oct 31, 2007 at 8:16 PM
Hi,

The configuration is looking for signed assemblies, so if you are referencing assemblies built from the source you're using the wrong assemblies. Take a look at this post from Tom Hollander describing this situation and explaining how to solve it http://blogs.msdn.com/tomholl/archive/2007/04/19/avoiding-configuration-pitfalls-with-incompatible-copies-of-enterprise-library.aspx.

Regards,
Fernando
Nov 1, 2007 at 1:56 AM
Fernando

Thank you --- the post was on point!!!!!!

Yes -- I was using the unsigned dll's