Beispiel #1
0
        //  Stopwatch stopwatch = new Stopwatch();

        public MainWindow()
        {
            InitializeComponent();

            SpecBackgroundWorker.RunWorkerAsync();
            TestsBackgroundWorker.RunWorkerAsync();
            //  DriversBackgroundWorker.RunWorkerAsync();

            if (_spec.BatteryCharge() != "n/a")
            {
                ChargeTimer.Enabled = true;
            }
            MySql database = new MySql("127.0.0.1", "3310", "cuser", "msasia", "log_instalacja");

            MessageBox.Show(database.CheckConnection().ToString());
        }
Beispiel #2
0
 private void SpecBackgroundWorker_DoWork(object sender, DoWorkEventArgs e)
 {
     _spec.GetManufacturer();
     SpecBackgroundWorker.ReportProgress(0);
     _spec.GetModel();
     SpecBackgroundWorker.ReportProgress(1);
     _spec.GetSerial();
     SpecBackgroundWorker.ReportProgress(2);
     _spec.GetCpu();
     SpecBackgroundWorker.ReportProgress(3);
     _spec.GetRam();
     SpecBackgroundWorker.ReportProgress(4);
     _spec.GetDiagonal();
     SpecBackgroundWorker.ReportProgress(5);
     _spec.GetResName();
     SpecBackgroundWorker.ReportProgress(6);
     _spec.GetGpu();
     SpecBackgroundWorker.ReportProgress(7);
     _spec.GetOpticalDrive();
     SpecBackgroundWorker.ReportProgress(8);
     _spec.GetOsBuild();
     SpecBackgroundWorker.ReportProgress(9);
     _spec.GetOsLanguages();
     SpecBackgroundWorker.ReportProgress(10);
     _spec.GetOsLicence();
     SpecBackgroundWorker.ReportProgress(11);
     _spec.GetOsName();
     SpecBackgroundWorker.ReportProgress(12);
     _spec.GetBatterHealth();
     SpecBackgroundWorker.ReportProgress(13);
     _spec.GetCameraPresence();
     SpecBackgroundWorker.ReportProgress(14);
     _spec.GetNetAdapters();
     SpecBackgroundWorker.ReportProgress(15);
     _spec.GetFprPresence();
     SpecBackgroundWorker.ReportProgress(16);
     _spec.GetDriverStatus();
     SpecBackgroundWorker.ReportProgress(17);
     _hdd.GetDisks();
     SpecBackgroundWorker.ReportProgress(18);
 }