Click here to Skip to main content
Rate this: bad
good
Please Sign up or sign in to vote.
See more: C#
I am referencing different projects,where code written in n-hibernate and i use the references files as
1. Antlr3.Runtime.dll
2. Iesi.Collections.dll
3. log4net.dll
4. Castle.Core.dll
5. Castle.DynamicProxy2.dll
6. NHibernate.dll
7. NHibernate.ByteCode.Castle.dll
8. NHibernate.Validator.dll
9. nunit.framework.dll
I got "FileLoadException was unhandled" Error.
details is:
"Could not load file or assembly 'NHibernate, Version=2.1.2.4000, Culture=neutral, PublicKeyToken=aa95f207798dfdb4' or one of its dependencies. The located assembly's manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040)"
 
please anyone help me about this.
Posted 27-Jan-13 21:58pm
Tanumay991.7K
Rate this: bad
good
Please Sign up or sign in to vote.

Solution 1

Hi Tanumay,
 
Could be a version issue, make sure the physical NHibernate is Version=2.1.2.4000 (we can see from the exception that this is the version is it looking for)
 
You might also check the GAC so see what version it is holding.
 
Cheers,
Edo
  Permalink  
v2
Comments
Tanumay99 at 29-Jan-13 4:13am
   
thanks for that solutions. but i checked the version. My NHibernate Version is 2.1.2.4000 and also i checked GAC,But still i got the same error
Rate this: bad
good
Please Sign up or sign in to vote.

Solution 2

Thanks, Edo Tzumer
 
I got my fault.
There is error in version
I solve it by the following code
<hibernate-configuration xmlns="urn:nhibernate-configuration-2.2">
and also i change my mapping assembly
<mapping assembly="Project"/>
Here Project is the resource type solutions where all the mapper as well as resource class present
and also i make version of the resource type and output type solutions same.
  Permalink  
v2

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
0 OriginalGriff 195
1 Afzaal Ahmad Zeeshan 152
2 ProgramFOX 130
3 Maciej Los 130
4 den2k88 80
0 OriginalGriff 6,564
1 Sergey Alexandrovich Kryukov 6,048
2 DamithSL 5,228
3 Manas Bhardwaj 4,657
4 Maciej Los 4,150


Advertise | Privacy | Mobile
Web04 | 2.8.1411022.1 | Last Updated 31 Jan 2013
Copyright © CodeProject, 1999-2014
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100