Ejemplo n.º 1
0
 public static void Main(string[] args)
 {
     Application.Init ();
     MainWindow win = new MainWindow ();
     win.Show ();
     Application.Run ();
 }
Ejemplo n.º 2
0
 public MainWindow()
 {
     log_file = new System.IO.FileStream("log3.txt", System.IO.FileMode.Append);
     log_sw = new System.IO.StreamWriter(log_file);
     InitializeComponent();
     ac_m = new ArchiveControl();
     Console.SetOut(log_sw);
     _LogTimer.Interval = System.TimeSpan.FromSeconds(5);
     _LogTimer.Tick += flushLog;
     _LogTimer.Start();
     Console.WriteLine("========================================");
     Console.WriteLine("MainWindow()");
     Console.WriteLine(DateTime.Now.ToString());
     log_sw.Flush();
     write.mainWindow = this;
     try
     {
         button_NP_Click(null, null);
         button_NS_Click(null, null);
     } catch { }
     TabItem1.Visibility = Visibility.Hidden;
     TabItem2.Visibility = Visibility.Hidden;
     TabItem3.Visibility = Visibility.Hidden;
     TabItem4.Visibility = Visibility.Hidden;
     //
     mainWindow = this;
     ac_m.count();
 }