Example #1
0
        public void  TryInit()
        {
            InitializeComponent();
            this.pageInput    = new InputForm(this);
            this.pageConfirm  = new Confirmation(this);
            this.pageViewList = new ViewList(this);
            this.cmdPool      = new CmdPool(new LocalDbService());
            string[]     args         = Environment.GetCommandLineArgs();
            const string CLEAR_TOKEN  = "-CLEAR";
            const string NOLIST_TOKEN = "-NOLIST";

            foreach (string x in args)
            {
                if (x.ToUpper().Equals(CLEAR_TOKEN))
                {
                    this.cmdPool.cmdInput.ClearDatabase();
                }
                if (x.ToUpper().Equals(NOLIST_TOKEN))
                {
                    this.pageInput.btnDisplayList.Visibility = System.Windows.Visibility.Hidden;
                }
            }
            this.pageInput.ResetContent();
            this.Content = this.pageInput;
        }
Example #2
0
        public void Init()
        {
            IDBService svc = new FakeDbService();

            cmd = new CmdPool(svc);
        }