View Single Post
  #14   Spotlight this post!  
Unread 30-12-2006, 18:46
Bob22341 Bob22341 is offline
Registered User
FRC #1870
 
Join Date: Jan 2006
Rookie Year: 2006
Location: Alberta
Posts: 48
Bob22341 will become famous soon enough
Re: Visual C++ 2005 Designer

Your problem comes when "child" calls "parent"

In c++ once you have included a file once, you can't do it again without causing build errors. You create a continual loop with including parent and chile again and again.

If you want to go into inheritance issues and calling parent functions you can, there is an easier way. Create another file called "parenta" and copy over all of the code from "parent" Then slightly change all of the function and class names to avoid build errors, and your almost done.

Change "child" to call "parenta" instead of "parent" and problem solved.

"parent" should include "child" which should include "parenta"

Hopefully that solves your problem