private void loadPaymentHistory() { PaymentHistory history = new PaymentHistory(DatabaseFactory.Default); history.StartDate = LoanBookForm.TimelineStartDate; history.EndDate = LoanBookForm.TimelineEndDate; history.Account = account; history.Loan = loan; historyGrid.DataSource = history.Summary; }
private void deleteToolStripMenuItem_Click(object sender, EventArgs e) { DialogResult result = Message.Confirm("Are you sure you want to delete this payment?", "Confirm Payment Removal"); if (result == System.Windows.Forms.DialogResult.Yes) { PaymentHistory history = new PaymentHistory(DatabaseFactory.Default); history.Remove(selectedPayment()); loadPaymentHistory(); dispatchFormUpdatedEvent(); } }