i makinh MCQs question as my mini project in windows form application i m facing few problem plzz solve that
1. to count the score of total correct question and show at the last in windows form
2. when i selct any option(radiobutton) then next question appears with same number of option as marked e.g if i selct option 2 in 1st question then 2nd question 2nd option appears as selected .. i wanted that options appears randmoly or blank.
private void Form1_Load(object sender, EventArgs e)
{
string constring ="Server=TAHIRA-7B0ECEAE\\SQLEXPRESS;integrated security=SSPI;database=MCQ";
SqlConnection conn = new SqlConnection (constring);
conn.Open();
string Sql = "select * from table_1";
SqlCommand cmd = new SqlCommand(Sql,conn);
SqlDataReader reader = cmd.ExecuteReader();
[B]Int score= 0;[/B]
while(reader.Read());
label1.Text=reader[0];
radioButton1.Text=reader[1].Tostring;
radioButton2.Text=reader[2].Tostring;
radioButton3.Text=reader[3].To.string;
[B]if(radiobutton1.checked=true)
{
score +1;
}
cmd.ExecuteNonQuery();
it must count score ov all question.. in which button i ve to code