private void bindingNavigatorAddNewItem_Click(object sender, EventArgs e) { using (源房抄表Form form = new 源房抄表Form()) { form.ShowDialog(this); } }
private void EditItem() { ObjectView <源房抄表> view = 源房抄表BindingSource.Current as ObjectView <源房抄表>; if (view != null && view.Object != null) { using (源房抄表Form form = new 源房抄表Form(view.Object)) { form.ShowDialog(this); } } }