SqlCommand command = new SqlCommand(); >>>>> //Congfigure command >>>>> SqlParameter param = new SqlParameter(Parameters[2, 0], Parameters[2, 1]); >>>>> param.Direction = ParameterDirection.InputOutput; >>>>> //etc >>>>> command.Parameters.Add(param); >>>>> //Add other params , execute.... >>>>> var v = command.Parameters["@Param3"].Value;>>>>
>>IDbDataParameter param = oCommand.CreateParameter(); >>>>
>>SqlParameter param = new SqlParameter(Parameters[2, 0], Parameters[2, 1]); >>Not sure why that wouldn't work. Assuming the command is DBCommand where does your code differ from this:
System.Data.Common.DbCommand command = new SqlCommand(); > System.Data.IDbDataParameter p = command.CreateParameter(); > p.ParameterName = "@Param3"; > p.Direction = ParameterDirection.InputOutput; > p.Value = cVal3; > //etc... > command.Parameters.Add(p); > var v = command.Parameters["@Param3"].Value;One more question, please. When you press . (period) after the close bracket (last line of your code), do you see Value as one of the properties? I only see Equals, GetHashCode, GetType, and ToString().