there is a message about "NHibernate.ProxyGenerators.CastleDynamicProxy" assembly.

Description

/****** following code is written into "default.aspx.cs of "quickstart project" ******/
using NHibernate;
using NHibernate.Tool.hbm2ddl;
using QuickStart;
protected void Page_Load(object sender, EventArgs e)
{
ISession session = NHibernateHelper.GetCurrentSession();

ITransaction tx = session.BeginTransaction();

Cat princess = new Cat();
princess.Name = "Princess";
princess.Sex = 'F';
princess.Weight = 7.4f;

session.Save(princess);
tx.Commit();

NHibernateHelper.CloseSession();

}

/**********following code is written into "Helper.cs" of "Cat.project"***************/
using NHibernate;
using NHibernate.Cfg;
public static ISession GetCurrentSession()
{

System.Web.HttpContext context = HttpContext.Current;
ISession currentSession = context.Items[CurrentSessionKey] as ISession;

if (currentSession == null)
{
currentSession = sessionFactory.OpenSession();
context.Items[CurrentSessionKey] = currentSession;
}

return currentSession;
}

I always get a error message . the VS.net said that you couldn't load file or assmebly "NHibernate.ProxyGenerators.CastleDynamicProxy" or a dependency of it . system cannot find the file...

How do I ?

Environment

None

Activity

Show:

Alex Zaytsev 
May 18, 2017 at 11:32 PM

I think this is obsolete. If not, please create an issue here: https://github.com/nhibernate/NHibernate.ProxyGenerators/issues/new

Obsolete

Details

Assignee

Reporter

Components

Affects versions

Priority

Who's Looking?

Open Who's Looking?
Created April 2, 2009 at 12:40 AM
Updated May 18, 2017 at 11:32 PM
Resolved May 18, 2017 at 11:32 PM
Who's Looking?