private void btnVoidItem_Click(object sender, EventArgs e) { this.CollectSettings(); DialogResult tempDialogResult = MessageBox.Show("Are you sure you want to void this order?", "Confirm", MessageBoxButtons.YesNo, MessageBoxIcon.Question); if (tempDialogResult.Equals(DialogResult.No)) return; //ITEM_VOID_INFORMATION n = new ITEM_VOID_INFORMATION(); //n.ShowDialog(); if (lsvRemovable.Items.Count < 1) { MessageBox.Show("There is no item to be void.Please select as removable items.", RMSGlobal.MessageBoxTitle, MessageBoxButtons.OK, MessageBoxIcon.Information); return; } else { if (MessageBox.Show("Ok Done", RMSGlobal.MessageBoxTitle, MessageBoxButtons.OK, MessageBoxIcon.Question) == DialogResult.OK) { COrderManager tempOrderManager = new COrderManager(); if (m_onlineOrderID < 1) { tempOrderManager.VoidPrintedItems(m_slOrderedItems, m_orderID);//Updatre DB with latest quantity status for local ordered items. } else { tempOrderManager.VoidOnlinePrintedItems(m_slOrderedItems); //For online ordered items } this.AddItemVoidReport(); this.KitchenPrintVoidCopy(); this.PrintBeverageVoidItems(); MessageBox.Show("Items are successfully sent to kitchen.", RMSGlobal.MessageBoxTitle, MessageBoxButtons.OK, MessageBoxIcon.Information); lsvRemovable.Items.Clear(); } } }