Login

Username

Password





Register   Reset password

This is a read-only archive of the forum.

# haighis 11/22/2006 3:41 PM
Hi,

I have created a UserImage entity (UserImage.cs and the Mapping File UserImage.hbm.xml) I get the following error.

Your help is greatly appreciated.

Association references unmapped class: UserImage
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: NHibernate.MappingException: Association references unmapped class: UserImage

Source Error:

Line 90: Configuration config = new Configuration();
Line 91: this._nhibernateConfiguration = config.AddAssembly(this.GetType().Assembly);
Line 92: this._nhibernateFactory = this._nhibernateConfiguration.BuildSessionFactory();
Line 93: }
Line 94: }


Source File: c:\nhibernate\3\core\service\sessionfactory.cs Line: 92

Thanks,

John Haigh
# martijnb 11/23/2006 2:43 AM
Have you set UserImage.hbm.xml to compile as embedded resource?

Btw, the NHibernate forum is a better place for questions like this.
# haighis 11/23/2006 8:47 AM
Hi,

I am not sure how to set UserImage.hbm.xml to compile as embedded resource?

Thanks,

John
# haighis 11/23/2006 10:29 AM
Hi,

After doing some searching around, I was able to figure out how to specify the UserImage.hbm.xml as an embedded resource:

Right click on the hbm.xml file in VS.NET
Set the Build Action to Embedded Resource

Thanks,

John Haigh