private void btnMSTSCstart_Click(object sender, EventArgs e) { if (tbMSTSCadress.Text != string.Empty) { MethodsServices.StartMSTSC(tbMSTSCadress.Text, tbMSTSClogin.Text, tbMSTSCpass.Text); } }
private void btnCyclePingStart_Click(object sender, EventArgs e) { lbCyclePing.Items.Clear(); MethodsServices.CyclePingStop = false; tbCyclePingAdress.Text = tbCyclePingAdress.Text.Replace(',', '.'); //Меняем *запятую* на *точку* MethodsServices.StartCyclePing(tbCyclePingAdress.Text, lbCyclePing); btnCyclePingStart.Enabled = false; }
private void btnRefreshPing_Click(object sender, EventArgs e) { //Останавливаем цикл пинга MethodsServices.PingStop = true; MethodsServices srvc = new MethodsServices(); srvc.LoadLBPing(pbPingProgress, lbPingSuccess, lbPingTimeOut, numPingTimeOut); }
private void Services_Load(object sender, EventArgs e) { numPingProgress.Value = Convert.ToDecimal(AiOMethods.LoadFromRegistry("ProgressBarSec", 30)); pbPingProgress.Maximum = Convert.ToInt32(numPingProgress.Value) * 1000; MethodsServices ms = new MethodsServices(); ms.RefreshLBRDPShare(lbRDP, "ServiceRDP"); ms.RefreshLBRDPShare(lbShare, "ServiceShare"); }
private void Services_VisibleChanged(object sender, EventArgs e) { //Чтобы при создании контрола Services первое событие VisibleChanged скипалось if (SkipFillingPB == false) { MethodsServices.PingStop = !Visible; if (Visible) { MethodsServices ms = new MethodsServices(); ms.FillingPB(pbPingProgress, lbPingSuccess, lbPingTimeOut, numPingTimeOut); } } }
private void chckbServiceSorted_CheckedChanged(object sender, EventArgs e) { if (chckbServiceSorted.Checked) { lbRDP.Sorted = true; lbShare.Sorted = true; lbPingSuccess.Sorted = true; lbPingTimeOut.Sorted = true; } else { lbRDP.Sorted = false; lbShare.Sorted = false; lbPingSuccess.Sorted = false; lbPingTimeOut.Sorted = false; } MethodsServices ms = new MethodsServices(); ms.RefreshLBRDPShare(lbRDP, "ServiceRDP"); ms.RefreshLBRDPShare(lbShare, "ServiceShare"); }