コード例 #1
0
        private void printVehicleData()
        {
            Console.WriteLine("choose one of the License numbers below: ");
            printAllVehicleLicense();
            string o_LicenseNumber = enterLicenseNumber();

            Console.Clear();
            string vehicleData = r_GarageLogic.GetVehicleData(o_LicenseNumber);

            Console.WriteLine(vehicleData);
        }
コード例 #2
0
        // Ask the user to select a vehicle and print all his data to the screen
        public void PrintVehicleData()
        {
            string licenseNumber;
            string vehicleData;

            try
            {
                licenseNumber = EnterLicenseNumber();
                vehicleData   = r_MyGarage.GetVehicleData(licenseNumber);
                Console.WriteLine(vehicleData);
            }
            catch (Exception ex)
            {
                Console.WriteLine(ex.Message);
            }
        }