title: How to read rows count using SqlDataReader
body: <p>I came across a stored procedure that is returning number of rows but am not sure how can I read number of rows here,</p>
  
  <p>Stored procedure is:</p>
  
  <pre><code>CREATE PROCEDURE [dbo].[Document_Exists]
  (
      @Url varchar(255)
  )
  AS
      SET NOCOUNT ON;
  
      SELECT COUNT(*) AS Rows 
      FROM Document_Instances 
      WHERE Url = @Url
  </code></pre>
  
  <p>Executed as</p>
  
  <pre><code>EXEC @return_value = [dbo].[Document_Exists]
       @SourceSiteUrl = N'https://cc23.dev.com/portal'
  
  SELECT 'Return Value' = @return_value
  </code></pre>
  
  <p>trying to read it with this code</p>
  
  <pre><code>SqlCommand cmd1 = new SqlCommand("Document_Exists", conn);
  cmd1.CommandType = CommandType.StoredProcedure;
  cmd1.Parameters.Add(new SqlParameter("@Url", url));
  SqlDataReader rdr1 = cmd.ExecuteReader();
  
  while (rdr1.Read())
  {
  </code></pre>
  
  <p>dunno what to do next</p>