c# for loop error in code
<p>I have the following code in c# and I am getting compilation error. Can anyone please help me?</p>

<p><strong>Update</strong></p>

<pre><code>protected void Page_Load(object sender, EventArgs e)
        {


            OleDbConnection con = new OleDbConnection("Provider=Microsoft.Jet.OLEDB.4.0; Data Source=|DataDirectory|OID.mdb;Persist Security Info=False;");
            //OleDbConnection con = new OleDbConnection("Data Source=sml; User ID=sml; Password=sml; provider=OraOLEDB.Oracle");

                OleDbCommand cmd = new OleDbCommand();
                //cmd.CommandText = "Select * from EMAILS WHERE EMAIL= '" + GlobalData.Email + "'";
                cmd.CommandText = "Select * from EMAILS";
                cmd.CommandType = CommandType.Text;
                cmd.Connection = con;
                OleDbDataAdapter da = new OleDbDataAdapter(cmd);
                DataSet ds = new DataSet();
                da.Fill(ds);

                foreach (DataRow row in ds.Tables[0].Rows)
               {

                   String email = row["email"].ToString();

                    if (email == GlobalData.Email)

                   {

                       Label2.Text = GlobalData.Email;
                       Label1.Text = GlobalData.Name;
                       Label3.Text = GlobalData.LastName;



                    }
                    else
                   {

                      Response.Redirect("login.aspx");

                    }



                }
        }
</code></pre>

<p>Now it is directly going to else section after the loop what will be error now</p>
