public async Task <ApplicationOlderVersionGrade> UpdateRC1GradeAndVersion(string version) { OlderVersionDal AppOldVersionDal = new OlderVersionDal(); Version oldVersionToSave = new Version(); var gradeValues = await ReportsRepository.getGradeValues("Application%20Grade"); double totalCalc = 100 - (5 * gradeValues.Item1) - (0.5 * gradeValues.Item2) - (0.1 * gradeValues.Item3); if (Version.TryParse(version, out oldVersionToSave)) { return(AppOldVersionDal.SetApplictionOldVersionRC1(oldVersionToSave.ToString(), totalCalc)); } return(default(ApplicationOlderVersionGrade)); }