private void OnCreateProjectButtonClick(object sender, EventArgs e) { var form = new FormProjectBudget() { ProjectKey = string.Empty }; form.ShowDialog(this); if (form.DialogResult == DialogResult.OK) { button4.PerformClick(); } }
private void EditCurrentProject(bool copy) { var rowView = gCBBindingSource.Current as DataRowView; if (rowView != null) { var row = rowView.Row as DataSet1.GCBRow; if (row != null) { var form = new FormProjectBudget() { ProjectKey = row.工程关键字, CopyProject = copy }; form.ShowDialog(this); } } }