/// <summary> /// Occurs when the user has selected the payment method to receive money on /// </summary> /// <param name="sender"></param> /// <param name="e"></param> void fpiGetPaymentMethod_FormClosing(object sender, FormClosingEventArgs e) { sPaymentMethod = fpiGetPaymentMethod.GetPaymentMethod(); if (sPaymentMethod == "DEPO") { MessageBox.Show("Sorry, you can't receive money on deposit paid."); } if (sPaymentMethod != "NULL" && sPaymentMethod != "DEPO") { tEngine.ReceiveMoneyOnAccount(sAccountCodeToReceive, fAmountToReceive, sPaymentMethod); tEngine.OpenTillDrawer(false); tEngine.PrintReceivedOnAccount(sAccountCodeToReceive, fAmountToReceive, sPaymentMethod); MessageBox.Show("Money successfully received."); } else { MessageBox.Show("Cancelled Receive on Account"); } this.Close(); }