title: List index Convert into datatable
body: <p>I have stored datatable at index 0, and int at index 1 in a List, now i want to convert list index 0 into datatable.. How it will get converted into datatable?</p>
  
  <pre><code>//Class Function
        public List&lt;object&gt; Login(string A, string B)
          {
  
             DataTable dt = new DataTable();
             xConn.Open();
             SqlCommand xComm = new SqlCommand("Ulogin");
             xComm.CommandType = CommandType.StoredProcedure;
             xComm.Connection = xConn;
             xComm.Parameters.AddWithValue("@Email", A);
             xComm.Parameters.AddWithValue("@Pass", B);
             int usercount = (Int32)xComm.ExecuteScalar();
             xComm.ExecuteNonQuery();
             new SqlDataAdapter(xComm).Fill(dt);
             List&lt;object&gt; L = new List&lt;object&gt;();
             L.Add(dt);
             L.Add(usercount);
             return L;
          }
  
  
         //Web Form
         protected void Sub_Click(object sender, EventArgs e)
         {
          string Email = TextBox3.Text;
          string Pass = TextBox4.Text;
          List&lt;object&gt; L = d.Login(Email,Pass);
          int I = Convert.ToInt32(L[1]);
          if (I &gt; 0)
          {
             //How does it convert here?
          }
          else
          {
              Response.Write("Incorrect Email Or Password");
          }
  
       }
  </code></pre>