DataAccess da = new DataAccess(); da.sqlPath = Config.Get("System", "dataCntString"); da.open(); SqlParameter[] SP = new SqlParameter[3]; SP[0] = new SqlParameter("@riskID", SqlDbType.VarChar); SP[0].Value = FormId; SP[1] = new SqlParameter("@riskLeaderIDs", SqlDbType.VarChar); SP[1].Value = userIds; SP[2] = new SqlParameter("@noUnits", SqlDbType.VarChar, 500); SP[2].Direction = ParameterDirection.Output; da.ExecuteNonReturn("CheckRiskAndSignSubmit", SP); da.close(); object noUnits = SP[2].Value; string strnoUnits = noUnits == null ? "" : noUnits.ToString();
三个参数,其中@noUnits 是输出。