private void btn_update_Click(object sender, EventArgs e) { Guid id = ((contacts)lst_list.SelectedItem).id; BusinessLogicLayer.BLL BLL = new BusinessLogicLayer.BLL(); int ReturnValues = BLL.updateRecord(id, txt_update_name.Text, txt_update_surname.Text, txt_update_number1.Text, txt_update_number2.Text, txt_update_number3.Text, txt_update_email.Text, txt_new_webadress.Text, txt_update_adress.Text, txt_update_info.Text); if (ReturnValues > 0) { MessageBox.Show("Successful!! Record Updated", "Info", MessageBoxButtons.OK, MessageBoxIcon.Information); addList(); } else { MessageBox.Show("Something wrong", "Info", MessageBoxButtons.OK, MessageBoxIcon.Information); } }