473,587 Members | 2,579 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

NHibernate and assembly issue

Hi,

In my C# project (VisitorManagem ent) I have a subfolder
(BusinessObject s) in which I have put the objects needed for NHibernate
and the mapping files.

In the top of my web service I do a using
VisitorManageme nt.BusinessObje cts; and I'm able to use these objects.
But When I invoke the web service I get the following error.

Code C#:
cfg = new Configuration() ;
cfg.AddAssembly ("VisitorManage ment.BusinessOb jects");

Error:
NHibernate.Mapp ingException: Could not add assembly named:
VisitorManageme nt.BusinessObje cts ---> System.IO.FileN otFoundExceptio n:
File or assembly name VisitorManageme nt.BusinessObje cts, or one of its
dependencies, was not found.
File name: "VisitorManagem ent.BusinessObj ects"

-----

Code C#:
cfg = new Configuration() ;
cfg.AddAssembly ("VisitorManage ment");

Error:
NHibernate.Mapp ingException: persistent class
VisitorManageme nt.BusinessObje cts.TblAuthoris ationLevel,Visi torManagement.B usinessObjects
not found ---> System.IO.FileN otFoundExceptio n: File or assembly name
VisitorManageme nt.BusinessObje cts, or one of its dependencies, was not
found.
File name: "VisitorManagem ent.BusinessObj ects"
It works if I put all the classes in the same folder, but I'd rather
stick to this alternative as it looks way cleaner.

If anybody knows how to sort this problem, I'll be gratefull.

Best reguards,

Pierre

Nov 17 '05 #1
0 3312

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

8
2719
by: Rob | last post by:
We are starting a new fairly big project based on the typical 3-tier approach (db, business, GUI layer). I have limited experience in that field but from my experience all the stored procedures, com object, etc is quite cumbersome and error prone. Therefore, I am currently looking into some OR Mappers. I did a very simple sample project with...
0
1099
by: Fabricio de Reuter Sperandio | last post by:
Hi everyone, could you help me with this error? The check of the signature failed for assembly 'NHibernate' Its works perfectly on my develop machine but after upload to the host server this error comes up. Thank you,
0
2851
by: Aquila Deus | last post by:
The documents on their website are completely wrong. Following is the a real example that works with NHibernate 1.0.2.0: <?xml version="1.0" encoding="utf-8"?> <configuration xmlns="http://schemas.microsoft.com/.NetConfiguration/v2.0"> <configSections> <!-- SecurityException is thrown if NHibernate assembly is not in GAC. --> <section...
1
13698
by: erin.sebastian | last post by:
Hello All, I am new to hibernate and new to nHibernate. I created a small app and when i try and run it i get the error i posted at the bottom of this message. I am using the helper class that can be found here http://blogs.intesoft.net/simon/articles/16.aspx#36 . Does anyone know why this error might occur.. i have NO IDEA.... if you...
1
2556
by: Ram | last post by:
Hey, I'm having a trouble mapping a connecting between 2 of my tables. We have 2 tables - the simplest "dept", "emp" tables which are mapped to 2 classes. Class Dept contains 2 properties for emps - 1 for manager and the second for workers (Collection). How can I map this? We can add additional fields in the emp table that indicates the...
1
12726
by: sternr | last post by:
Hey, I'm using NHibernate version: 1.0.0.2 My Mapping documents: <class name="DM.Book" table="Books"> <id column="bookId" name="bookId"> <generator class="assigned" /> </id> <property column="name" name="name" />
5
3104
by: igotyourdotnet | last post by:
I took over an asp.net C# app from a former developer that left. Ever so ofter I get an error message: Access is denied: 'NHibernate'. 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. ...
0
2419
by: Sean Chambers | last post by:
This is a fairly simple architecture question, just can't seem to wrap my head around the answer. I am using NHibernate 1.2 from the trunk to leverage generics support. I have a User Table that has 4 different types of users: Patron Promoter Admin
4
3329
by: IceMan | last post by:
Hi, I am using the configuration object and passing it a Assembly object to load. The assembly object i pass in is from a dll which is in a different folder then the Nhibernate dll. The AddAssembly(Assembly assembly) function throws me an Error saying it can't load the configuration hbm.xml file because it can't load the assembly in the...
0
8206
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. ...
1
7967
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For...
0
8220
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the...
1
5713
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes...
0
5392
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert...
0
3840
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in...
1
2353
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
1
1452
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
1185
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.