Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

Want to inherit from CObject using MS VC++ v5 ClassWizard

Posted on 1998-01-27
3
Medium Priority
?
371 Views
Last Modified: 2006-11-17
New to MS Visual C++ but not to C++ programming in general. I'm building an app with MS VC++ v5, and want to create a class which inherits from CObject, not one of its derivatives (this is a base class for other "work" objects I'll create, not an object associated with UI processing). Would like to use Class Wizard so I can build components for reuse in other apps. Can this be done? If so, what are the steps? If not, any alternative approaches you can suggest?
0
Comment
Question by:frlaunt
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 2

Accepted Solution

by:
mitchell042997 earned 200 total points
ID: 1179318
Choose the menu option Insert / Insert Class.  Now, just name your class and choose the base class to be CObject.  This class will now reside in ClassWizard and have all of the default comments and preprocessor marks MFC kindly enters for you.
0
 

Author Comment

by:frlaunt
ID: 1179319
Super! I'll give it a try. Thanks for your help.
0
 

Author Comment

by:frlaunt
ID: 1179320
Super! I'll give it a try. Thanks for your help.
0

Featured Post

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Errors will happen. It is a fact of life for the programmer. How and when errors are detected have a great impact on quality and cost of a product. It is better to detect errors at compile time, when possible and practical. Errors that make their wa…
  Included as part of the C++ Standard Template Library (STL) is a collection of generic containers. Each of these containers serves a different purpose and has different pros and cons. It is often difficult to decide which container to use and …
The viewer will learn how to pass data into a function in C++. This is one step further in using functions. Instead of only printing text onto the console, the function will be able to perform calculations with argumentents given by the user.
The viewer will learn additional member functions of the vector class. Specifically, the capacity and swap member functions will be introduced.

715 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question