Ejemplo n.º 1
0
    static void Main(string[] args) {

      var config = WSRConfig.GetInstance();
      if (!config.Parse(args).Validate()) {
        return;
      }

      try {
        // Setup logging
        config.SetupLogging();

        // Start Process
        Application.EnableVisualStyles();
        Application.SetCompatibleTextRenderingDefault(false);

        // Buid WSRMicro or Kinect
        config.Start();

        // Build System Tray
        using (WSRTrayMenu tray = new WSRTrayMenu()) {
          tray.Display();
          Application.Run(); // Make sure the application runs!
        }
      } 
      catch(Exception ex){
        config.logError("CATCH_ALL", ex);
      }
    }
Ejemplo n.º 2
0
        static void Main(string[] args)
        {
            var config = WSRConfig.GetInstance();

            if (!config.Parse(args).Validate())
            {
                return;
            }

            try {
                // Setup logging
                config.SetupLogging();

                // Start Process
                Application.EnableVisualStyles();
                Application.SetCompatibleTextRenderingDefault(false);

                // Buid WSRMicro or Kinect
                config.Start();

                // Build System Tray
                using (WSRTrayMenu tray = new WSRTrayMenu()) {
                    tray.Display();
                    Application.Run(); // Make sure the application runs!
                }
            }
            catch (Exception ex) {
                config.logError("CATCH_ALL", ex);
            }
        }