Exemplo n.º 1
0
        protected override void OnStart(string[] args)
        {
            logger = LogManager.GetCurrentClassLogger();

            DDnsSharpRuntime.MakeBackup();

            timer          = new Timer(REGULAR_INTERVAL);
            timer.Elapsed += timer_Elapsed;
            timer.Start();

            OnJob();
        }
Exemplo n.º 2
0
        public MainWindow()
        {
            mconfig = MonitorIoc.Current.Get <MonitorConfig>();
            ViewModelLocator.Setup();
            DDnsSharpRuntime.MakeBackup();
            DDnsSharpRuntime.LoadAppConfig();
            var config = DDnsSharpRuntime.AppConfig;

            if (String.IsNullOrWhiteSpace(config.Email) ||
                String.IsNullOrWhiteSpace(config.Password))
            {
                ShowLoginWindow();
            }
            else
            {
                InitializeComponent();
                Login();
            }
        }