SHARE
TWEET

Untitled

a guest Feb 18th, 2019 60 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. private void BtnDodaj_Click(object sender, EventArgs e)//Dodaj means Add in Croatian
  2.         {
  3.             if (DTPVracanje.Checked == false)//DTPvracanje is a datetimepicker
  4.             {
  5.                 for (int Row = 0; Row < DataGridView.Rows.Count;  Row++)
  6.                 {
  7.                     if (DataGridView.Rows[Row].Cells[1].Value.ToString() == CboSifraKnjige.Text &&
  8.                         DataGridView.Rows[Row].Cells[5].Value.Equals(Convert.IsDBNull(DTPVracanje.Value)))//column 5 contains DBnull if DTPVracanje is unchecked
  9.                     {
  10.                         MessageBox.Show("Knjiga je vani");//Book is out in Croatian[
  11.                     }
  12.                     else
  13.                     {
  14.                         Dodaj();
  15.                     }
  16.                 }
  17.             }          
  18.         }
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top