예제 #1
0
        private void btn_add_Click(object sender, EventArgs e)
        {
            AddIPPLC frm = new AddIPPLC();

            if (frm.ShowDialog() == DialogResult.OK)
            {
                searchdata(ref dgv_ip, true);
            }
        }
예제 #2
0
        private void btn_edit_Click(object sender, EventArgs e)
        {
            AddIPPLC frm = new AddIPPLC();

            Class.valiballecommon va = Class.valiballecommon.GetStorage();
            va.value1 = dgv_ip.Rows[dgv_ip.SelectedCells[0].RowIndex].Cells[1].Value.ToString();
            va.value2 = dgv_ip.Rows[dgv_ip.SelectedCells[0].RowIndex].Cells[2].Value.ToString();
            va.value3 = dgv_ip.Rows[dgv_ip.SelectedCells[0].RowIndex].Cells[3].Value.ToString();
            va.value4 = dgv_ip.Rows[dgv_ip.SelectedCells[0].RowIndex].Cells[4].Value.ToString();
            va.value5 = dgv_ip.Rows[dgv_ip.SelectedCells[0].RowIndex].Cells[5].Value.ToString();
            va.value6 = dgv_ip.Rows[dgv_ip.SelectedCells[0].RowIndex].Cells[6].Value.ToString();

            if (frm.ShowDialog() == DialogResult.OK)
            {
                searchdata(ref dgv_ip, true);
            }
        }