private void btnAdd_Click(object sender, EventArgs e)
        {
            frmAddVehicle addVehicleForm = new frmAddVehicle();
            Vehicle       vehicle        = addVehicleForm.GetNewVehicle();

            if (vehicle != null)
            {
                vehicles.Add(vehicle);
            }
        }
示例#2
0
        private void btnAdd_Click(object sender, EventArgs e)
        {
            frmAddVehicle addCustomerForm = new frmAddVehicle();
            Vehicle       vehicle         = addCustomerForm.GetNewVehicle();

            if (vehicle != null)
            {
                vehicles.Add(vehicle);
                VehicleDB.SaveVehicle(vehicles);
                FillVehicleListBox();
            }
        }