private void btn_Edit_Click(object sender, EventArgs e) { int i = dgv_main.CurrentCell.RowIndex;//获取选中行索引 ServerModel server = servers[i]; CreateServer createServer = new CreateServer(this, server); createServer.ShowDialog(); }
private void btn_Create_Click(object sender, EventArgs e) { CreateServer createServer = new CreateServer(this); createServer.ShowDialog(); }