There are lots of possible reasons:
1)
count
could be wrong: this would probably cause an "array index out of range" error.
2) The data in your DataGridView might be in the wrong format for the cells.
3) You might need a password on your DB.
4) The name of the database could be wrong.
5) You may already have identical data in your database.
6) Your database may require other information in order to do the insert.
7) You could be trying to compile this as VB.
8) Other.
Without the actual error message, it is impossible to say.
However, do not do it that way anyway: you leave yourself open to an accidental or deliberate SQL Injection attack. Use Parametrized queries instead:
string qu = "INSERT INTO feesstudcture (Fees_name, Amount) VALUES (@FEN, @AMT)";
string constring = "data source=localhost;database=newschool;userid=root;password=";
MySqlConnection con = new MySqlConnection(constring);
con.Open();
MySqlCommand cmd = new MySqlCommand(qu, con);
cmd.Parameters.AddWithValue("@FEN", dataGridView1.Rows[i].Cells["Fees_name"].Value);
cmd.Parameters.AddWithValue("@AMT", dataGridView1.Rows[i].Cells["Amount"].Value);
cmd.ExecuteNonQuery();
Oh, and move the connection outside the loop - you do not need to create a new one each time you go round!