Problems with the variable position, C#
<p>What's wrong with the code?
Why on the second report shows a mistake?</p>

<pre><code>string level;
int key;

command.CommandText = "SELECT * FROM user WHERE name = 'admin'";

connection.Open();
Reader = command.ExecuteReader();

while (Reader.Read())
{
    level = Convert.ToString(Reader["level"]);
    key = Convert.ToInt32(Reader["key"]);

    MessageBox.Show(level); //Work fine
}

MessageBox.Show(level); //Show error:  Use of unassigned local variable 'level'
</code></pre>
