private void btnCRC_Click(object sender, EventArgs e) { if (txtBookNumber.Text != "") { if (!CopyDAO.CheckAvailableCopy(int.Parse(txtBookNumber.Text))) { MessageBox.Show("You can reserve this book."); btnReserve.Enabled = true; } else { txtBookNumber.Text = ""; btnReserve.Enabled = false; MessageBox.Show("This book still have available copy."); } } else { MessageBox.Show("Book Code can not be blank."); } }