public void Insert(object sender, EventArgs e) { using (uscOznakaPrimitkaElement user_control = new uscOznakaPrimitkaElement(Enums.FormEditMode.Insert)) { if (user_control.ShowDialogForm("Oznaka primitka element") == DialogResult.OK) { LoadGridOznakaPrimitakElement(); } } }
public void Update(object sender, EventArgs e) { if (ugdOznakaPrimitkaElement.ActiveRow != null) { BusinessLogic.pID = (int)ugdOznakaPrimitkaElement.ActiveRow.Cells["ID"].Value; BusinessLogic.pJOPPDOznaka = (int)ugdOznakaPrimitkaElement.ActiveRow.Cells["JOPPDOznakaPrimitkaID"].Value; BusinessLogic.pElement = (int)ugdOznakaPrimitkaElement.ActiveRow.Cells["IDELEMENT"].Value; using (uscOznakaPrimitkaElement user_control = new uscOznakaPrimitkaElement(Enums.FormEditMode.Update)) { if (user_control.ShowDialogForm("Oznaka primitka element") == DialogResult.OK) { LoadGridOznakaPrimitakElement(); } } } }