You need to remove the brackets in the SQL statement
string sql = "SELECT COUNT(*) FROM account WHERE Access_Control = @code"
;
If you need use a keyword in MySQL you wrap it in two
` `
like
`Table`
(Don't know what this character is called, though)
[UPDATE]
Just for the fun of it, test this
com.Parameters.Add("@code", SqlDbType.VarChar);
com.Parameters["@code"].Value = metroaccesscontroltxtBox.Text;
instead of
com.Parameters.AddWithValue("@code", metroaccesscontroltxtBox.Text);