예제 #1
0
        public BaseContainerTest()
        {
            if (File.Exists("sga.db"))
                File.Delete("sga.db");

            Container = new SgaContainer();
            Container.SetupForDesktop();
            Container.Register(Component.For<DataTestManager>());
            //Container.Register(Component.For<SchemaUtil>());
        }
예제 #2
0
        static void Main()
        {
            logger = LogManager.GetLogger(typeof(Program));

            try
            {
                XmlConfigurator.Configure();

                container = new SgaContainer();
                container.SetupForDesktop();
                RegisterDesktopUI();

                Application.EnableVisualStyles();
                Application.SetCompatibleTextRenderingDefault(false);

                Application.Run(container.Resolve<IMainView>() as Form);

            }
            catch (Exception ex)
            {
                logger.Error("Crash error: ", ex);
                ShowError(ex);
            }
        }