question about CObjet inherit...

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I'm starting whit C++, so I don't andestand too much about .

I would like to know how can I inherit a generic class fron
CObjet class, all the time I try I recibe a message telling that
CObjet class is not defined,
I have tried making this with SDI, MDI, but nothing work,
according with a a book that I have, say that the header of CObject class
is already included, but I always encouter this problem.
CAN SAMBODY HELP ME TO SOLVE THIS PROBLEM??????.
I realy will apreciate your help, ...([email protected] or
(e-mail address removed))
 
OK !
In MSDN you one can read
"
CObject is the principal base class for the Microsoft Foundation Class
Library. It serves as the root not only for library classes such as CFile and
CObList, but also for the classes that you write. CObject provides basic
services, including

Serialization support
Run-time class information
Object diagnostic output
Compatibility with collection classes

Note that CObject does not support multiple inheritance. Your derived
classes can have only one CObject base class, and that CObject must be
leftmost in the hierarchy. It is permissible, however, to have structures and
non-CObject-derived classes in right-hand multiple-inheritance branches.

You will realize major benefits from CObject derivation if you use some of
the optional macros in your class implementation and declarations.
"
Maybe it will help.

In addition I should say that in the "Add class" part of the "classView" (in
"Workspace")
if it's not possible to set the CObject Class as "base class", you can
derive you class from derived class of CObject which is indirectely what you
ask for.
Just decide which one is relevant to your will.
If I understood you well, the trouble is fixed !
Regards
XL
 
Back
Top