Here is my code: ( It is not working)
sc.Open();
cmd = new SqlCommand("SELECT COUNT (*) FROM Records", sc);
Int32 count = (Int32)cmd.ExecuteScalar();
if (count >= 0)
for (int i = 1; i < count; i++)
cmd = new SqlCommand("Insert into Records(Num, Faculty, Intake, Location, Years, University, Fees, Courses) values('" +1+ "','" + DropDownList5.SelectedItem.Text + "','" + DropDownList2.SelectedItem.Text + "','" + DropDownList4.SelectedItem.Text + "','" + DropDownList6.SelectedItem.Text + "','" + DropDownList7.SelectedItem.Text + "','" + TextBox1.Text + "','" + TextBox2.Text + "')", sc);
sc.Close();