Error in function overloading. Cin dont print out anything
error c2679, error c3847, error c2601, error c1075
Collapse
X
-
error c2679, error c3847, error c2601, error c1075
Tags: None -
First, vehicleName is a member function of typeOfVehicle. But the () are missing.Code:cin >> microcar[count].vehicleName;
Second, you would need an operator>>(type OfVechicle&, typeOfVehicle:: vehicleName*), which doesn't exist. Hence the error.
The whole thing looks fishy. I suspect you want to enter the name of the vehicle using a typeOfVehicle object:
where typeOfVehicle:: SetVehicleName( ) does the cin.Code:microcar[count].SetvehicleName();
BTW: I notice the vehicleName is a char. Mighty short name. Maybe use a C++ string object.
Comment