Пример #1
0
 public Ustawienia(Sterowanie other)
 {
     this.other = other;
     InitializeComponent();
     if (other.PozMode == "G90")
     {
         radioButton1.Checked = true;
         radioButton2.Checked = false;
     }
     else if (other.PozMode == "G91")
     {
         radioButton1.Checked = false;
         radioButton2.Checked = true;
     }
 }
Пример #2
0
        private void Button1_Click(object sender, EventArgs e)
        {
            if (comboBox1.SelectedItem.ToString() == "VIRTUAL")
            {
                VIRTUAL  = true;
                baudrate = "0";
            }
            else
            {
                VIRTUAL = false;
            }
            com = comboBox1.SelectedItem.ToString();
            if (comboBox2.Text != "")
            {
                baudrate = comboBox2.SelectedItem.ToString();
            }
            Sterowanie fr = new Sterowanie(com, baudrate, VIRTUAL, this);

            fr.Show();
            this.Hide();
        }