1
Answer

Mark a row containing a bool value as conditional

Mehmet Fatih

Mehmet Fatih

1y
311
1

I have 3 rickboxes in the form. I fill them at different times. When the last rickbox is filled, I want the column named “tamamlandi” that contains the bool value to mark as checked. But I couldn't succeed. I need your help on this matter.

This is my code. 

string kayit = "update mytablename set  tamamlandi=@tamamlandi

 if (txt_gorusme1.Text != string.Empty && txt_gorusme2.Text != string.Empty && txt_gorusme3.Text != string.Empty)
 {
     komut.Parameters.AddWithValue("@tamamlandi", true);
 }
 else
 {
     komut.Parameters.AddWithValue("@tamamlandi", DBNull.Value);
 }

Answers (1)