i have one table name is room in this roomno is one column and in front-end windows form i have my design when i select roomnumber using combobox it start compare weather the roomnumber is already reserved or not
please any one provide the code
Ranjit PowarPosted Dec 22, 2015, 1:14 AM
DataTable dt=new DataTable();
da.Fill(dt);
if(dt.Rows.Count>0)
chennakrishnareddy bijivemulaPosted Dec 22, 2015, 12:53 AM
Ranjit PowarPosted Dec 22, 2015, 12:38 AM
chennakrishnareddy bijivemulaPosted Dec 22, 2015, 12:17 AM
Ranjit PowarPosted Dec 21, 2015, 9:44 AM
SqlDataAdapter da= new SqlDataAdapter("select status from room where roomno='"+comboBox1.Text+"'",con);
DataTable dt=new DataTable();
da.Fill(dt);
string status=DT.Rows[0][0].ToString();