private void metroTileDocumentAdd_Click(object sender, EventArgs e) { var Form = new GeneralDocumentsEntityForm(); Form.sdf = this; Form.Show(); }
private void buttonInputEdit_Click(object sender, EventArgs e) { try { var dId = dataGridViewInput.SelectedCells[0].Value.ToString(); if (String.IsNullOrEmpty(dId)) { throw new Exception("Не выбран документ"); } var Form = new GeneralDocumentsEntityForm(); Form.Id = dataGridViewInput.SelectedCells[0].Value.ToString(); Form.sdf = this; Form.Show(); } catch (Exception gg) { MessageBox.Show(gg.Message, "SWA", MessageBoxButtons.OK, MessageBoxIcon.Error); } }