private void btnAddInterval_Click(object sender, EventArgs e) { var f = new BillingAfterIntervalEditor(new Billing.DL.Dates(1)); f.ShowDialog(); if (f.DialogResult != DialogResult.OK) { return; } dates.Add(f.Dates); RefreshList(); }
private void button2_Click(object sender, EventArgs e) { if (listInterval.SelectedItems.Count == 0) { return; } var index = listInterval.SelectedIndex; var f = new BillingAfterIntervalEditor(dates[index]); f.ShowDialog(); if (f.DialogResult != DialogResult.OK) { return; } dates[index] = f.Dates; RefreshList(); }