I currently have a derived class and a base class. How can I make the base class of the derived class equal to a base class that I have? Will a shallow copy work?
Just change this.
Derived d = (Derived)b;
Also, your name data type should be string, not int