void getValueButton_Click(object sender, EventArgs e) { var makeId = int.Parse(makeDropDown.SelectedValue); var year = int.Parse(yearDropDown.SelectedValue); var conditionId = int.Parse(conditionDropDown.SelectedValue); var args = new CarValueArgs { MakeId = int.Parse(makeDropDown.SelectedValue), Year = int.Parse(yearDropDown.SelectedValue), ConditionId = int.Parse(conditionDropDown.SelectedValue) }; var carValueService = new CarValueService(); //var carValue = carValueService.GetValue(makeId, conditionId, year); var carValue = carValueService.GetValue(args); valueLiteral.Text = carValue.ToString("c"); }
public decimal GetValue(CarValueArgs args) { Thread.Sleep(5000); return(_rand.Next(10000, 20000)); }
public decimal GetValue(CarValueArgs args) { Thread.Sleep(5000); return _rand.Next(10000, 20000); }