title: Procedure or function expects parameter which was not supplied
body: <p>Driving me mad on a personal project; I know I've done this before but elsewhere and don't have the code.  As far as I can see, I'm setting the parameter, I'm setting its value, the connection is open, yet when I try to fill the dataset I get the error 'Procedure or function expects parameter "@test" which was not supplied'. </p>
  
  <p>(This is obviously a simplified test! Same error on this or the real, rather longer code though.)</p>
  
  <p>C#:</p>
  
  <pre><code>SqlCommand l_oCmd;
  DataSet l_oPage = new DataSet();
  
  l_oCmd = new SqlCommand("usp_test", g_oConn);
  l_oCmd.Parameters.Add(new SqlParameter("@test", SqlDbType.NVarChar));
  l_oCmd.Parameters[0].Value = "hello world";
  
  SqlDataAdapter da = new SqlDataAdapter(l_oCmd);
  da.Fill(l_oPage);
  </code></pre>
  
  <p>SQL:</p>
  
  <pre><code>create procedure usp_test
  (
      @test nvarchar(1000)
  )
  as
  select @test
  </code></pre>
  
  <p>What have I missed?</p>