Ejemplo n.º 1
0
        public Window1()
        {
            try
            {
                dataAccess = new DataAccess();

                string type = ConfigurationSettings.AppSettings["TYPE"];
                appTimer = new System.Timers.Timer(1 * 1000);
                appTimer.AutoReset = false;
                appTimer.Elapsed += new ElapsedEventHandler(appTimer_Elapsed);

                xmlSerializer = new XmlSerializer(typeof(AndonAlertEventArgs));

                InitializeComponent();
                

                appTimer.Start();

                
            }
            catch (Exception e)
            {
                MessageBox.Show(e.Message, "Application Error", MessageBoxButton.OK, MessageBoxImage.Error);
                Window_Closing(this, new CancelEventArgs());
            }
        }
Ejemplo n.º 2
0
 public Reports()
 {
     InitializeComponent();
    
     dataAccess = new DataAccess();
 }