public string DeleteCar(string id) { try { Car carResult = carMethods.GetCarById(Convert.ToInt16(id)); carMethods.RemoveCar(carResult.Regnumber); return("Car is successfully deleted:)"); } catch { return("Could not delete the car:("); } }
public bool RemoveCar(string regnum) { return(carMethods.RemoveCar(regnum)); }
public void DeleteCar(string regnum) { carMethods.RemoveCar(regnum); }