Code behind:mySqlCommand.Parameters.Add(New Data.SqlClient.SqlParameter("@RecordCount", Data.SqlDbType.Int)) mySqlCommand.Parameters("@RecordCount").Direction = Data.ParameterDirection.Output mySqlCommand.CommandType = Data.CommandType.StoredProcedure mySqlCommand.CommandText = ("sp_ZyTax_Get_Record_Count_jTable") mySqlCommand.Connection = mySqlConnection mySqlCommand.ExecuteScalar() Return myRecordCount = mySqlCommand.Parameters("@RecordCount").ValueStored Procedure:@RecordCount int outputasBEGIN set nocount on select count(*) from ZyTax.dbo.jTable set @RecordCount = @@ROWCOUNT END GO