private void btnAddCost_Click(object sender, EventArgs e) { if (!string.IsNullOrEmpty(txtOrderNO.Text)) { string info = txtOrderNO.Text + @"," + lblManName.Text + @"," + lblWname.Text + @"," + txtMoblePhone1.Text + @"," + txtMoblePhone2.Text; FrmAddCost frmAddCost = new FrmAddCost(info); frmAddCost.ShowDialog(); } else { MessageBox.Show(@"订单号无效!"); } }
private void 新增消费ToolStripMenuItem_Click(object sender, EventArgs e) { if (dgvShowOrders.CurrentCell.Value == null) { MessageBox.Show(@"请选中需操作的订单!"); return; } if (dgvShowOrders.SelectedCells.Count > 1) { MessageBox.Show(@"该操作只允许点击一个单元格!"); return; } FrmAddCost frmAddCost = new FrmAddCost(dgvShowOrders.CurrentCell.Tag.ToString()); frmAddCost.ShowDialog(); }