private void showBestellingEditForm() { BestellingAddEdit bestellingEditForm = new BestellingAddEdit((Bestelling)lvBestellingen.SelectedItems[0].Tag, kwekerij.Planten, kwekerij.Klanten); bestellingEditForm.ShowDialog(); if (bestellingEditForm.DialogResult == DialogResult.OK) { refreshMainView(); } }
private void bestellingToolStripMenuItem_Click(object sender, EventArgs e) { BestellingAddEdit bestellingAddForm = new BestellingAddEdit(new Bestelling(0), kwekerij.Planten, kwekerij.Klanten); bestellingAddForm.ShowDialog(); if (bestellingAddForm.DialogResult == DialogResult.OK) { kwekerij.Bestellingen.Add(bestellingAddForm.Bestelling); refreshMainView(); } }