private void button2_Click(object sender, EventArgs e) { int salesid = Convert.ToInt16(txtorderid.Text); if (_release.isAllRelease(salesid, false) == true) { //update to complete if (_release.CompleteRelease(salesid, 0) == true) { s.CompleteSales(salesid, "Completed", ""); MessageBox.Show("Transactions are complete"); } } else { MessageBox.Show("There still items not yet released cannot complete the transactions"); } }