public static QueRenEnd CreateForm(binddata bind, int id, string dannumber, bindsx bdsx) { binsx = bdsx; dannum = dannumber; ID = id; bind1 = bind; if (_danli == null) { _danli = new QueRenEnd(); } return(_danli); }
private void button4_Click(object sender, EventArgs e) { List <int> list = new List <int>(); string dannumber = ""; foreach (DataGridViewRow iteam in dataGridView1.Rows) { if (Convert.ToBoolean(iteam.Cells["XZ"].Value)) { list.Add(Convert.ToInt32(iteam.Cells["jcID"].Value)); dannumber = iteam.Cells["jcDanNumber"].Value.ToString(); } } if (list.Count != 1) { MessageBox.Show("请选择一条数据!"); return; } QueRenEnd quend = QueRenEnd.CreateForm(ZhiXing, list[0], dannumber, hsuaxin); quend.Show(); quend.Focus(); }
private void QueRenEnd_FormClosing(object sender, FormClosingEventArgs e) { _danli = null; }