SqlDataReaderUse instead SqlDataAdapter.
SqlDataAdapter myAdapter = new SqlDataAdapter(command);
myAdapter.Fill(datatable);
With the help of SqlDataAdapteryou do not need to explicitly call SqlConnection.Open()and SqlConnection.Close(). It is processed by the method Fill().
user596075