private void BT_Speed_Click(object sender, EventArgs e) { if (gv.GetFocusedDataSourceRowIndex() < 0 || gv.RowCount < 1) { MessageBox.Show("没有路径"); return; } Batch_Speed frm = new Batch_Speed(CBE_RecipeName.EditValue.ToString()); frm.ShowDialog(); CBE_RecipeName_TextChanged(this, null); }