예제 #1
0
        private void btnSecondWeight_Click(object sender, EventArgs e)
        {
            // prevWieght prevWieght = new prevWieght(new second_weight());
            //prevWieght.Show();
            serial.Disconnect();
            second_weight second_Weight = new second_weight();

            second_Weight.Show();
            second_Weight.loadDataById(Convert.ToInt32(label12.Text));
            this.Hide();
        }
예제 #2
0
 private void btnOk_Click(object sender, EventArgs e)
 {
     try
     {
         int selected = (int)dataGridView1.Rows[dataGridView1.CurrentRow.Index].Cells[0].Value;
         _second.loadDataById(selected);
         _second.Show();
         this.Hide();
     }
     catch (Exception ex)
     {
         MessageBox.Show(ex.Message, "خطأ", MessageBoxButtons.OK, MessageBoxIcon.Error);
     }
 }