Let's take a minute and convert the configuration from the Ordering.Console
application to an App.config
configuration.
Open the
Program.cs
orModule1.vb
file, depending on which language you are using.Comment out the existing
cfg.SetProperty
lines, using either the//
or'
depending on your language. Make sure you leave the statement where you "new it up" as we will use that again. When you are finished, your code should look as follows:Configuration cfg = new Configuration(); //cfg.SetProperty("connection.provider", //"NHibernate.Connection.DriverConnectionProvider"); //cfg.SetProperty("dialect", //"NHibernate.Dialect.MsSql2008Dialect"); //cfg.SetProperty("connection.connection_string_name", //"Ordering"); //cfg.SetProperty("proxyfactory.factory_class", //"NHibernate.ByteCode.LinFu.ProxyFactoryFactory, //NHibernate.ByteCode.LinFu"); //cfg.AddAssembly(typeof(Address...