title: Why am I getting "Error: datatable does not exist in current context" in this try-catch block?
body: <p>Here is my code which works:</p>
  <pre><code>DataTable myDataTable = new DataTable();
  try
  {
      // Code Logic
  }
  catch (Exception exp)
  {
      //Handle Exception
  }
  finally
  {
      myDataTable.Dispose();
  }
  </code></pre>
  <p>It looks fine and shows no compile error</p>
  <p>But when I declare the datatable inside the try potion it shows an error:</p>
  <blockquote>
  <p>The name 'myDataTable' does not exist in the current context</p>
  </blockquote>
  <p>Here is the code attempting this:</p>
  <pre><code>try
  {
      DataTable myDataTable = new DataTable();
  }
  catch (Exception exp)
  {
      //Handle Exception
  }
  finally
  {
      myDataTable.Dispose();
  }
  </code></pre>
  <p>Why is this happening?</p>