Just to make sure you really understand why this happened:
vector<Base> obj;Child1 c1;obj.push_back(c1);
The push_back
copies the instance you want to push into the vector. But you tell the vector it deals with Base objects. Hence you get what you ask for, a new instance of Base filled with just this part of the Child1 instance c1. Inside your vector you now only have an instance of class Base.
Now consider the suggestion to use (smart) pointers (non-smart in this case so take care of memory de-allocation afterwards:
vector<Base*> obj;Child1 *c1 = new Child1;obj.push_back(c1);
Now the vector just takes pointers. It copies the pointer (hence the address the pointer points to in memory) to the vector. While it is true that the vector does now hold pointers of Base* type it does not matter. Because you use virtual functions calling func() on the pointer looks up the virtual function table of actual object pointed to and calls the function from the Child1 interface. Calling (virtual) functions using pointers takes care that you call the function of the class you used to create an object.
------------------------------------I always enjoy being rated up by you ...