honar abubakr

honar abubakr

  • NA
  • 73
  • 110.6k

No data exists for the row/column error

Jul 26 2013 7:08 AM
i have an error in this peace of code in my project in c# and access 2010
update_st_card is a textbox for card_id

         ol_com.CommandText = "select [card_id] from student_info where [card_id] NOT IN ('"+update_st_card.Text+"')";
                reader = ol_com.ExecuteReader();
                //current_card_id = Convert.ToInt32(update_st_card.Text.ToString());
                if ((string)reader["[card_id]"] == update_st_card.Text)
                {
                    up_st_lbl2.Text = "error card_id is entered before";
                }//end check for card id repeate or not if

                else
                {
                 //here i do update operation
                  }


Answers (6)