title: SP TimeOut in .NET code, not in Management Studio
body: <p>If I run the following in Management Studio (SQL Server 2008) :</p>
  
  <pre><code>exec [USP_CNT_BookingDetail_ExtractAccountingPlanData] '4AFD6633-CB90-4165-913D-EE3EA74708DA', '7EF7CCB2-E09F-4408-AE2D-F857C063F2C1'
  </code></pre>
  
  <p>I get the result back in less than a second</p>
  
  <p>I however I run it in VB.Net like this :</p>
  
  <pre><code>Using aConnection = New System.Data.SqlClient.SqlConnection(*** Some Connection String ***)
    aConnection.Open()
    Dim aCmd = aConnection.CreateCommand()
    aCmd.CommandText = "exec [USP_CNT_BookingDetail_ExtractAccountingPlanData] '4AFD6633-CB90-4165-913D-EE3EA74708DA', '7EF7CCB2-E09F-4408-AE2D-F857C063F2C1'"
    aCmd.ExecuteNonQuery()
    aConnection.Close()
  End Using
  </code></pre>
  
  <p>it times out (I know that ExecuteNonQuery does not return data, but I tried to keep the code as small as possible).</p>
  
  <p>I've used the same DB, UserID and password in code as in the Management Studio en the Isolation Level is Read Comitted.</p>
  
  <p>Anybody has any idea ?</p>