Since you didn't supply any code, I am going to write my own. Your classes should look something like this.
class ID {
public:
string name;
string ID;
};
class Employee : ID {};
int main(int argc, char **argv) {
cin >> Employee.Info.ID;
}
There are alot of things wrong with the line:
cin >> Employee.Info.ID;
First of all Employee extends Info. It is not a member of Info. This means that all the members of Info become members of Employee. So the code would change to:
cin >> Employee.ID;
But there is still something wrong with this code. ID is an instance variable. Employee is not an instance it is a class. I am not entire sure what you want to do but there are two ways to fix this: 1) make ID a static variable or 2) create an instance of Employee.
1)
class ID {
public:
string name;
static string ID; // Change to static
};
2)
int main(int argc, char **argv) {
Employee my_employee; // Create instance
cin >> my_employee.ID;
What 1) does is set the ID's of all employers to the first word in cin. What 2) does is set the ID of my_employee (the instance we created) only.